Skip to main content

Module markup

Module markup 

Source
Expand description

Inline styling inside a text param:

  • *word*: the emphasis style, set by the node’s em_* params.
  • [words]{color=#ffd23f weight=800 font="Instrument Serif"}: a span with its own attributes (color, font, weight, style, size, highlight, underline, rise).
  • \*, \[ and \\ set the characters themselves. A * without a partner, or brackets without {...} after them, stay literal.

Structs§

Span
A styled byte range of the plain text.

Enums§

Style

Functions§

escape
Escapes s so markup sets it literally.
has_markup
Whether s has anything markup would change.
parse
The plain text and its styled spans.
plain
The text a reader sees: markup removed.