HighlightedCodeBlockBuilder class
A MarkdownElementBuilder for the 'pre' tag that renders fenced code
blocks with syntax highlighting via the highlight package.
Uses inline highlight parsing instead of HighlightView to avoid rendering failures on Flutter web where HighlightView.build can throw (producing a grey error box in release mode).
- Inheritance
-
- Object
- MarkdownElementBuilder
- HighlightedCodeBlockBuilder
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
isBlockElement(
) → bool -
For block syntax has to return true.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
visitElementAfter(
Element element, TextStyle? preferredStyle) → Widget? -
Called when an Element has been reached, after its children have been
visited.
inherited
-
visitElementAfterWithContext(
BuildContext context, Element element, TextStyle? preferredStyle, TextStyle? parentStyle) → Widget? -
Called when an Element has been reached, after its children have been
visited.
override
-
visitElementBefore(
Element element) → void -
Called when an Element has been reached, before its children have been
visited.
override
-
visitText(
Text text, TextStyle? preferredStyle) → Widget? -
Called when a text node has been reached.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited