Markup
Term.markup.MarkupTag
Term.markup.SingleTag
Term.markup.SingleTag
Term.markup.clean_nested_tags
Term.markup.clean_nested_tags
Term.markup.extract_markup
Term.markup.has_markup
Term.markup.pairup_tags
Term.markup.MarkupTag
— TypeMarkupTag
Represents a complete markup tag.
It stores two SingleTag
, the text inbetween and any other MarkupTag
that was detected in that text.
Term.markup.SingleTag
— TypeSingleTag
Represents a single tag [style]
or [/style]
Term.markup.SingleTag
— MethodSingleTag(match::RegexMatch)
Construct a SingleTag
out of a RegexMatch
Term.markup.clean_nested_tags
— Methodclean_nested_tags(text::AbstractString)::AbstractString
Given a text with nested string like: [red]aaaa [green]bbbb[/green] cccc [blue] ddddd [/blue]eeee[/red]
it adds extra tags to ensure that text within inner tags is handled properly, giving: [red]aaaa [green]bbbb[/green][red] cccc [/red][blue] ddddd [/blue][red]eeee[/red]
Term.markup.clean_nested_tags
— Methodclean_nested_tags(tag, text::AbstractString)
recursively applies to inner tags
Term.markup.extract_markup
— Methodextract_markup(input_text::AbstractString; firstonly=false)
Extracts MarkupTag
s from a piece of text.
Term.markup.has_markup
— Methodhas_markup(text::AbstractString)
Returns true
if text
includes a MarkupTag
Term.markup.pairup_tags
— Methodpairup_tags(text::Vector{AbstractString})
Given a vector of string with markup tags not properly closed/opened across lines, it fixes things up.