pub enum ContentKind {
Opaque,
Prose,
TokenList,
}Expand description
How the formatter treats an argument’s content — its whitespace and break
policy. Exactly one kind per slot (replaces the former mutually-exclusive
prose/collapse bools). Only meaningful for the formatter; the parser
ignores it (AGENTS.md decision #2).
Variants§
Opaque
Left exactly as authored: names, identifiers, code, or option lists
(\label, the \newcommand body). The default, so an unmarked argument
never reflows — for most arguments interior whitespace can matter (a
minipage/\parbox body, a label key).
Prose
Running prose the formatter may reflow to the line width (e.g. a
\footnote/\caption body, a sectioning title).
TokenList
A comma-separated token list whose interior whitespace is insignificant,
so the formatter may collapse a multi-line authored form to a single line
(a \citep/\cite key list). Unlike Prose, the
content is not reflowed to the width: the keys stay together as one atom;
only incidental source line breaks inside the braces are normalized away,
so \citep{\n a,\n b\n} formats identically to \citep{a, b} (determinism).
Trait Implementations§
Source§impl Clone for ContentKind
impl Clone for ContentKind
Source§fn clone(&self) -> ContentKind
fn clone(&self) -> ContentKind
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more