widget/all library
Classes
- BlockquoteConfig
- config class for Block quotes, tag: blockquote
- BlockquoteNode
- Tag: MarkdownTag.blockquote
- BrNode
- Tag: MarkdownTag.br
- CheckBoxConfig
- config class for checkbox, tag: input
- CodeBlockNode
- Tag: MarkdownTag.pre
- CodeConfig
- config class for code, tag: code
- CodeNode
- Tag: MarkdownTag.code the code textSpan
- ConcreteElementNode
- the default concrete node for ElementNode
- DelNode
- Tag: MarkdownTag.del
- ElementNode
- this node will accept other SpanNode as children
- EmNode
- Tag: MarkdownTag.em
- H1Config
- config class for h1
- H2Config
- config class for h2
- H3Config
- config class for h3
- H4Config
- config class for h4
- H5Config
- config class for h5
- H6Config
- config class for h6
- HeadingConfig
- config class for heading
- HeadingDivider
- only support h1 and h2
- HeadingNode
- Tag: MarkdownTag.h1 ~ MarkdownTag.h6
- HrConfig
- config class for HrNode
- HrNode
- Tag: MarkdownTag.hr
- ImageNode
- Tag: MarkdownTag.img
- ImageViewer
- show image with InteractiveViewer
- ImgConfig
- config class for image, tag: img
- InputNode
- Tag: MarkdownTag.input
- LinkConfig
- config class for link, tag: a
- LinkNode
- Tag: MarkdownTag.a
- ListConfig
- config class for list, tag: li
- ListNode
- Tag MarkdownTag.li
- MarkdownBlock
- use MarkdownBlock to build markdown by Column it does not support scrolling by default, but it will adapt to the width automatically.
- MarkdownWidget
- MarkdownWidgetState
- MCheckBox
- the check box widget
- ParagraphNode
- Tag: MarkdownTag.p
- PConfig
- config class for paragraphs, tag: p
- PreConfig
- config class for pre
- ProxyRichText
-
use ProxyRichText to give
textScaleFactor
a default value - SpanNode
- the basic node
- SpanNodeGeneratorWithTag
- use SpanNodeGeneratorWithTag that you can custom your own SpanNodeGenerator with tag
- StrongNode
- Tag: MarkdownTag.strong
- TableConfig
- TableNode
- TBodyNode
- TdNode
- TextNode
- text node only displays text
- THeadNode
- ThNode
- TrNode
- UlOrOLNode
- Tag MarkdownTag.ol、MarkdownTag.ul
- WidgetVisitor
- use WidgetVisitor that can transform MarkdownNode to SpanNodes and you can use SpanNode with Text.rich or RichText to get widget
Functions
-
convertHiNodes(
List< Node> nodes, Map<String, TextStyle> theme, TextStyle? style, TextStyle? styleNotMatched) → List<TextSpan> -
getDefaultMarker(
bool isOrdered, int depth, Color? color, int index, double paddingTop, MarkdownConfig config) → Widget - get default marker for list
-
highLightSpans(
String input, {String? language, bool autoDetectionLanguage = false, Map< String, TextStyle> theme = const {}, TextStyle? textStyle, TextStyle? styleNotMatched, int tabSize = 8}) → List<InlineSpan> - transform code to highlight code
-
wrapByAutoScroll(
int index, Widget child, AutoScrollController controller) → Widget -
wrap widget by
AutoScrollTag
that can useAutoScrollController
to scrollToIndex
Typedefs
- CheckBoxBuilder = Widget Function(bool checked)
- define a function to return a checkbox widget
- CodeBuilder = Widget Function(String code, String language)
- CodeWrapper = Widget Function(Widget child, String code, String language)
- ErrorImgBuilder = Widget Function(String url, String alt, Object error)
-
ImgBuilder
= Widget Function(String url, Map<
String, String> attributes) - ListMarker = Widget? Function(bool isOrdered, int depth, int index)
- the function to get marker widget
- SpanNodeAcceptCallback = void Function(SpanNode node, int nodeIndex)
-
when a
SpanNope
is visited, this callback will be triggered - SpanNodeGenerator = SpanNode Function(Element e, MarkdownConfig config, WidgetVisitor visitor)
- use SpanNodeGenerator will return a SpanNode
- TextNodeGenerator = SpanNode? Function(Node node, MarkdownConfig config, WidgetVisitor visitor)
- use TextNodeGenerator to custom your own TextNode
- WidgetWrapper = Widget Function(Widget child)
-
wrap
child
by another widget