MatchText class

A MatchText class which provides a structure for ParsedText to handle Pattern matching and also to provide custom Function and custom TextStyle.

Constructors

MatchText({ParsedType type = ParsedType.CUSTOM, String? pattern, TextStyle? style, dynamic onTap(String)?, Map<String, String> renderText({required String pattern, required String str})?, Widget renderWidget({required String pattern, required String text})?})
Creates a MatchText object

Properties

hashCode int
The hash code for this object.
no setterinherited
onTap ↔ (dynamic Function(String)?)
A custom Function to handle onTap.
getter/setter pair
pattern String?
If no type property is explicitly defined then this propery must be non null takes a regex string
getter/setter pair
renderText ↔ (Map<String, String> Function({required String pattern, required String str})?)
A callback function that takes two parameter String & pattern
getter/setter pair
renderWidget ↔ (Widget Function({required String pattern, required String text})?)
A callback function that takes the text the matches the pattern and returns the Widget to be displayed inside a WidgetSpan
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
style TextStyle?
Takes a custom style of TextStyle for the matched text widget
getter/setter pair
type ParsedType
Used to enforce Predefined regex to match from
getter/setter pair

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited