[][src]Function ftml::prefilter

pub fn prefilter(text: &mut String, handle: &dyn RemoteHandle) -> Result<()>

Transform the text in preparation for parsing.

Performs the following modifications:

  • Insert [[include]] directives
  • Replacing DOS and legacy Mac newlines
  • Trimming whitespace lines
  • Concatenating lines that end with backslashes
  • Convert tabs to four spaces
  • Compress groups of 3+ newlines into 2 newlines
  • Converts quote blocks to nested [[quote]] tags
  • Perform typography modifications