-
Notifications
You must be signed in to change notification settings - Fork 3
ISODoc: Text Blocks
BasicBlock = ( figure | admonition | example | table | sourcecode | quote | paragraph_with_footnote )
paragraph =
element p { ParagraphType }
Alignments = ( "left" | "right" | "center" | "justified" )
ParagraphType =
attribute id { xsd:ID },
attribute alignment { Alignments }?,
( TextElement )*, review*
paragraph_with_footnote =
element p {
attribute id { xsd:ID },
attribute alignment { Alignments }?,
( TextElement | fn )*, review*
}
review =
element review {
attribute id { xsd:ID },
attribute reviewer? { text },
attribute date { text },
paragraph+
}
formula =
element formula {
attribute id { xsd:ID },
stem, dl?
}
quote =
element quote {
attribute id { xsd:ID },
attribute alignment { Alignments }?,
quote_source?,
quote_author?,
paragraph_with_footnote+
}
quote_source =
element source { CitationInfo }
quote_author =
element author { CreatorInfo }
sourcecode =
element sourcecode {
attribute id { xsd:ID },
tname?, ( text | callout )+, annotation*
}
table =
element table {
attribute id { xsd:ID },
name?, thead?, tfoot?, tbody, table_note*, dl?
# note should not be paragraph with footnote, given that tables can be footnoted already
# tbody obligation is 1..* not 0..*
}
thead = element thead { tr }
tfoot = element tfoot { tr }
tbody = element tbody { tr+ }
table_note = element note { ParagraphType }
tr =
element tr { ( td | th )+ }
td =
element td {
attribute colspan? { text },
attribute rowspan? { text },
attribute align? { "left" | "right" | "center" },
(
(TextElement | review )* |
paragraph_with_footnote+
)
}
th =
element th {
attribute colspan? { text },
attribute rowspan? { text },
attribute align? { "left" | "right" | "center" },
(
(TextElement | review )* |
paragraph_with_footnote+
)
}
example =
element example {
attribute id { xsd:ID },
( formula | ul | ol | dl | quote | sourcecode | paragraph_with_footnote | review )+
}
admonition =
element admonition {
attribute type ( { "warning" | "note" | "tip" | "important" | "caution" } ),
attribute id { xsd:ID },
paragraph_with_footnote*
}
figure =
element figure {
attribute id { xsd:ID },
source?, tname?, (figure | TextElement*, note*, dl? )
}
Items for discussion (threaded: identify by number)
-
table/identifier, figure/identifier: changed from anchor, need to be consistent (in fact, I’d rather the clause/identifier change to anchor)
-
Addressed in https://github.com/riboseinc/isodoc-models/issues/3
-
-
table/note: note should not be paragraph with footnote, given that tables can be footnoted already
-
Addressed in https://github.com/riboseinc/isodoc-models/issues/3
-
-
table/tbody: tbody obligation is 1..* not 0..*
-
Addressed in https://github.com/riboseinc/isodoc-models/issues/3
-
-
td: I’d be more comfortable with the contents of td being TextElement than paragraph_with_footnote
-
Addressed in https://github.com/riboseinc/isodoc-models/issues/3
-
-
example/list: list in the UML includes callout lists, but callout lists do not belong in example: list needs to be redefined
-
Addressed in https://github.com/riboseinc/isodoc-models/issues/3
-
-
BasicBlock/clause: why is this here? blocks in the logical model receive their clause id from their context, so this does not need to be specified
-
Addressed in https://github.com/riboseinc/isodoc-models/issues/3
-
-
formula/stemValue, formula/stemType: These can be replaced with formula/InlineFormula (which I will call
stem
in the grammar`)-
I’m still calling FormulaBlock
formula
, it’s InlineForumla that should be renamedstem
.-
Addressed
-
-
-
sourcecode, formula, table, example, figure: these do not inherit paragraphs; you should instead add paragraphs to Admonition and Example, and make Paragraph a subclass of BasicBlock.
-
Addressed
-
-
sourcecode has a Value attribute of text, for the listing itself
-
Addressed
-
-
I would make id an attribute of the superclass BasicBlock; id is an attribute of several of these.
-
Addressed
-
-
Actually, both th and td can be either TextTableCell or ParagraphTableCell.
-
Addressed
-
-
Do Figure/Id and Figure/Anchor mean different things?
-
Addressed
-