class markdown::BlockStart

sys::Obj
  markdown::BlockStart

@Js

Source

Resulting object for starting parsing of a block. See BlockParserFactory.

atColumn

This atColumn(Int newColumn)

Source

Continue parsing at the specified column (for tab handling)

atIndex

This atIndex(Int newIndex)

Source

Continue parsing at the specified index

blockParsers

BlockParser[] blockParsers { private set }

Source

isReplaceActiveBlockParser

Bool isReplaceActiveBlockParser := false { private set }

Source

newColumn

Int newColumn := -1 { private set }

Source

newIndex

Int newIndex := -1 { private set }

Source

none

static new none()

Source

Result when there is no block start

of

static new of(BlockParser[] blockParsers)

Source

Start block(s) with the specified parser(s)

replaceActiveBlockParser

@Deprecated { msg=... }
This replaceActiveBlockParser()

Source

replaceParagraphLines

Int replaceParagraphLines := 0

Source

withReplaceParagraphLines

This withReplaceParagraphLines(Int lines)

Source

Replace a number of lines from the current paragraph (as returned by MatchedBlockParser.paragraphLines) with the new block.

This is useful for parsing blocks that start with normal paragrapsh and only have special marker syntax in later lines, e.g. in this:

Foo
===

The Foo line is initially parsed as a normal paragraph, then the === is parsed as a heading marker, replacing the 1 paragraph line before. The end result is a single Heading block.

Note that source spans from the replaced lines are automatically added to the new block.

Paramter lines indicates the number of lines to replace (at least 1); use Int.maxVal to replace the paragraph.