1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
//! The presentation vocabulary: the elements every lowering rule stages and
//! every backend's emitter reads.
//!
//! A **presentation element** is an element that never occurs in a source
//! document. A [lowering rule](crate::core::lowering::LoweringRule) stages
//! (builds into the lowered tree) nodes of presentation elements while it
//! rewrites a frozen tree, a backend writes these elements natively, and that
//! backend's emitter turns them into output. The presentation elements of
//! this module form the vocabulary every backend shares, so a lowering rule
//! that stages only these elements works for every backend. See [backends, lowering,
//! and outputs](crate::guide::concepts_overview#backends-lowering-and-outputs).
//!
//! A **presentation node** is a node of a presentation element: a callable
//! node of the presentation form
//! ([`FlmCallableType::Presentation`](crate::lang::FlmCallableType)).
//! Everything such a node states beyond its element and its children is one
//! **typed payload** held in the node extension
//! ([`FlmNodeExt::payload`](crate::lang::FlmNodeExt::payload)): a span's
//! display style, a block's role and kinds, a link's target, the anchor of a
//! node that is a link target. A node has no open set of properties and no
//! handler per backend. An emitter that cannot express a field of a payload
//! ignores it, so an output format may lose a detail of presentation; it
//! never loses content.
//!
//! A presentation node's children are grouped into named **content slots**
//! (the `body`, a list's `label` and `item` pairs, the `cell` slots of a
//! table of cells),
//! followed by one **attached slot** per decoration the lowering driver moved
//! out of the node's content. A decoration is a node whose element carries
//! the [`Decoration`] aspect; see [decorations, roles and
//! kinds](crate::guide::concepts_overview#decorations-roles-and-kinds) and
//! [`read`].
//!
//! The vocabulary is `par`, `block`, `block-heading`, `runin-heading`, `span`,
//! `list`, `cells`, `lines`/`line`, `verbatim`, `math-passthrough`, `math-text`,
//! `link`, `image`, `unsupported`, `dropped`, `unknown`, `deco.runin`,
//! `deco.final`, `deco.margin`, `deco-mark` and `subtree`, each spelled
//! `flm.pres.<name>` ([`ALL`]). It has no catch-all element: an extension that
//! needs another presentation element registers it, with its own payload
//! type, through
//! [`FeatureBuilder::presentation_element`](crate::core::registry::FeatureBuilder::presentation_element).
//!
//! # Module map
//!
//! - [`names`] — the element names, the slot names, the kind tokens of a
//! list, and the three groups of elements to which registration attaches
//! an aspect ([`DECORATIONS`], [`OPAQUE`], [`CONTENT_IN_OPAQUE`]).
//! - [`payload`] — the payload types, their projections (the serialized form
//! a test or a dump reads) and the readers that rebuild them
//! ([`payload_readers`]).
//! - [`length`] — the [`Length`] value, an exact amount and a unit: how a
//! payload states a dimension.
//! - [`aspects`] — the [`Decoration`], [`OpaqueContent`] and
//! [`ContentInOpaque`] aspects.
//! - [`mod@register`] — the registration of the whole vocabulary.
//! - [`read`] — reading presentation nodes: payloads, slots, decorations, list
//! entries, a table's cells, plain text, byte-exact source text, heading
//! depth, and the two tests a backend makes before it writes a stop after a
//! run-in heading.
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use register;