Expand description
Support for TeX-like Alignments
§Representation of aligned structures
An “Alignment” is an array/tabular construct as:
<tabular><tr><td>...
or, for math mode
<XMArray><XMRow><XMCell>...
(where initially, each XMCell will contain an XMArg to indicate
individual parsing of each cell’s content is desired)
An Alignment object is a sort of fake Whatsit; It takes some magic to sneak it into the Digestion stream (see TeX.pool \lx@begin@alignment), but it needs to be created BEFORE the contents of the alignment are digested, since we stuff a lot of information into it (row, column boxes, borders, spacing, etc…) But once it has been captured, it should otherwise act like a Whatsit and be responsible for construction (be_absorbed), and sizing estimation (computeSize)
Ultimately, this should be better tied into DefConstructor because an Alignment currently doesn’t know what CS created it (debugging!); Also, it would better connect the things being constructed, reversion, etc.
Modules§
Structs§
Enums§
- RowDisposition
- What becomes of the row being built at its end, asked by a binding from inside the row (longtable’s
\kill, its\caption’s row); the alignment carries it so a nested one cannot take it.
Constants§
- ALIGNMENT_
IS_ DISPLAY - The alignment property of an alignment that is a display by itself in TeX,
$$\halign…$$: amsmath’s align and gather families (amsmath.sty\start@align,\start@gather), latex.ltx’seqnarrayand IEEEtrantools’IEEEeqnarray(IEEEtrantools.sty:2013). Not cases.sty’snumcases, whose\halignis inside a\vbox(cases.sty:73-75). amsmath’smultlineis a display too but is not marked: its material is kept in the formula (TeX: “Improper \halign inside $$’s”), the safe direction. Set by the bindings (latexml_engine::tex_tables). - RULE_
COLOR - The colour of the horizontal rule being drawn, as colortbl’s
\CT@arc@gives it (colortbl.sty:166-192): set by the binding in the rule’s group, taken byAlignment::add_line.
Functions§
- declare_
column_ rule_ token - Declares
csa token of a column rule, which the template scans skip as they skip\vrule. - is_
column_ rule_ token - Whether a column template token draws (or paints) a column rule the cell-edge scan strips:
\vruleor a token a binding declared (declare_column_rule_token). - matrix_
template - parse_
alignment_ template - read_
alignment_ template - a reader for the Template parameter type
- take_
rule_ color - Takes the colour
RULE_COLORholds for the rule being drawn (None: the default ink).