Module spirt::print::pretty

source ·
Expand description

Pretty-printing functionality (such as automatic indentation).

Modules§

  • Color palettes built-in for convenience (colors are RGB, as [u8; 3]).

Structs§

  • Columns 🔒
    Fractional number of columns, used here to account for Node::StyledText being used to intentionally reduce the size of many “helper” pieces of text, at least for the HTML output (while this may lead to a less consistently formatted plaintext output, making good use of width is far more important for the HTML output, especially when used with multiversion tables).
  • Part of a pretty document, made up of Nodes.
  • MaxWidths 🔒
    Maximum numbers of columns, available to a Node, for both inline layout and block layout (i.e. multi-line with indentation).

Enums§

  • The approximate shape of a Node, regarding its 2D placement.
  • Break 🔒
  • LineOp 🔒
    Line-oriented operation (i.e. as if lines are stored separately).
  • TextOp 🔒
    Text-oriented operation (plain text snippets interleaved with style/anchor push/pop).

Constants§

Functions§