TextParserTempl

Parses text from XML/ETML

See "ETML.md" for further info on how the ETML format works.

Constructors

this
this(dstring _input, CharacterFormattingInfo!BitmapType _defFrmt)

Creates a new instance with a select string input.

Members

Aliases

ChrFormat
alias ChrFormat = CharacterFormattingInfo!BitmapType
Undocumented in source.
TextType
alias TextType = TextTempl!BitmapType
Undocumented in source.

Functions

closeFormattingTag
void closeFormattingTag()
Undocumented in source. Be warned that the author may not have intended to support it.
closeTextBlockIfNotEmpty
void closeTextBlockIfNotEmpty()
Undocumented in source. Be warned that the author may not have intended to support it.
defaultFormatting
CharacterFormattingInfo!BitmapType defaultFormatting()

Gets the default formatting

hasChrFormatting
sizediff_t hasChrFormatting(ChrFormat frmt)
Undocumented in source. Be warned that the author may not have intended to support it.
input
dstring input()

Sets/gets the input

onBrElement
void onBrElement()
Undocumented in source. Be warned that the author may not have intended to support it.
onElementEmpty
void onElementEmpty(dstring name, dstring[dstring] attr)
Undocumented in source. Be warned that the author may not have intended to support it.
onElementEnd
void onElementEnd(dstring name)
Undocumented in source. Be warned that the author may not have intended to support it.
onElementStart
void onElementStart(dstring name, dstring[dstring] attr)
Undocumented in source. Be warned that the author may not have intended to support it.
onFontElementStart
void onFontElementStart(dstring[dstring] attributes)
Undocumented in source. Be warned that the author may not have intended to support it.
onFormatDefElement
void onFormatDefElement(dstring[dstring] attributes)
Undocumented in source. Be warned that the author may not have intended to support it.
onFormatElementStart
void onFormatElementStart(dstring[dstring] attributes)
Undocumented in source. Be warned that the author may not have intended to support it.
onFrontTabElement
void onFrontTabElement(dstring[dstring] attributes)
Undocumented in source. Be warned that the author may not have intended to support it.
onIElementStart
void onIElementStart(dstring[dstring] attributes)
Undocumented in source. Be warned that the author may not have intended to support it.
onImageElement
void onImageElement(dstring[dstring] attributes)
Undocumented in source. Be warned that the author may not have intended to support it.
onLineFormatElementStart
void onLineFormatElementStart(dstring[dstring] attributes)
Undocumented in source. Be warned that the author may not have intended to support it.
onPElementStart
void onPElementStart(dstring[dstring] attributes)
Undocumented in source. Be warned that the author may not have intended to support it.
onText
void onText(dstring content)
Undocumented in source. Be warned that the author may not have intended to support it.
onTextElementStart
void onTextElementStart(dstring[dstring] attributes)

Begins a new text chain, and flushes the font stack.

parse
void parse()

Parses the formatted text, then sets the output values.

removeTopFromFrmtStack
void removeTopFromFrmtStack()
Undocumented in source. Be warned that the author may not have intended to support it.
testFormatting
void testFormatting(ChrFormat frmt)
Undocumented in source. Be warned that the author may not have intended to support it.

Variables

chrFrmt
ChrFormat[] chrFrmt;

All character format, that has been parsed so far

customEntities
dstring[dstring] customEntities;

Custom entities that are loaded during parsing.

fontsets
Fontset!BitmapType[string] fontsets;

Fontset name association table

frmtStack
ChrFormat[] frmtStack;

Character formatting stack.

icons
BitmapType[string] icons;

Icon name association table

namedFormats
ChrFormat[string] namedFormats;

Named format lookup table.

output
TextType[string] output;

All texts found within the ETML file

Meta