Skip to main content

Module outline

Module outline 

Source
Expand description

Shared paragraph classification for outline/list semantics.

Single truth source for “what kind of paragraph is this” across format encoders and read surfaces. The precedence chain was historically embedded in the Markdown styled encoder; it is lifted here so every consumer (Markdown export, document outline, read projections) agrees:

  1. paragraph-shape outline level (StyleLookup::para_heading_level) — the format-agnostic truth source for headings
  2. paragraph-shape list semantics (StyleLookup::para_list_type plus para_list_level / para_checked_state)
  3. style heading level (StyleLookup::style_heading_level)
  4. style-name list heuristic — Korean style names containing 글머리 or 개조 imply a bullet list, 번호 a numbered list. This is a documented heuristic inherited from the Markdown encoder and kept intentionally narrow; new name patterns need explicit justification.

Paragraph::heading_level is not consulted: that field carries titleMark / TOC-marker semantics, which is a different axis from paragraph-shape outline lists.

Classification is pure paragraph-shape/style semantics: paragraph text is never consulted. Renderers keep their own empty-text guards (an empty heading or list item renders as nothing, but that is a rendering concern).

Enums§

HeadingSource
Which axis produced a ParaKind::Heading classification.
ListItemKind
List marker family of a ParaKind::ListItem.
ListSource
Which axis produced a ParaKind::ListItem classification.
ParaKind
Semantic kind of a paragraph as resolved through the shared precedence chain.

Functions§

classify_paragraph
Classifies paragraph through the shared outline/list precedence chain.