WrappableText class

An immutable span of inline content which forms a paragraph. Only useful as a child of a FloatColumn, which provides the capability of wrapping the paragraph around child widgets that "float" to the right or left.

Annotations

Constructors

WrappableText({Key? key, required TextSpan text, FCClear clear = FCClear.none, TextAlign? textAlign, TextDirection? textDirection, TextOverflow? overflow, @Deprecated('Use textScaler instead. ' 'Use of textScaleFactor was deprecated in preparation for the upcoming ' 'nonlinear text scaling support. ' 'This feature was deprecated after v3.12.0-2.0.pre.') double textScaleFactor = 1.0, TextScaler textScaler = TextScaler.noScaling, int? maxLines, Locale? locale, StrutStyle? strutStyle, TextHeightBehavior? textHeightBehavior, double indent = 0.0, EdgeInsetsGeometry margin = EdgeInsets.zero, EdgeInsetsGeometry padding = EdgeInsets.zero})
Creates a paragraph of rich text, that when used in a FloatColumn can wrap around floated siblings.
WrappableText.fromRichText(RichText text)
WrappableText.fromText(Text text)

Properties

clear FCClear
Should this paragraph "clear" (i.e. be placed below) floated siblings? And if so, should it be placed below floated siblings on just one side (left, right, start, or end) or both? The default is none.
final
hashCode int
The hash code for this object.
no setteroverride
indent double
First line indent value. Defaults to zero. If it is negative, the text is laid out with a hanging indent.
final
key Key?
Unique key for this object.
final
locale Locale?
Used to select a font when the same Unicode character can be rendered differently, depending on the locale.
final
margin EdgeInsetsGeometry
Empty space to surround the paragraph. Similar to CSS, the top overlaps the previous sibling's bottom margin, the bottom overlaps the next sibling's top margin, and the left and right overlap floated siblings.
final
maxLines int?
An optional maximum number of lines for the text to span, wrapping if necessary. If the text exceeds the given number of lines, it will be truncated according to overflow.
final
overflow TextOverflow?
How visual overflow should be handled.
final
padding EdgeInsetsGeometry
Empty space to surround the paragraph that does not overlap siblings.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
strutStyle StrutStyle?
The strut style to use. Strut style defines the strut, which sets minimum vertical layout metrics.
final
text TextSpan
The text to display in this widget.
final
textAlign TextAlign?
How the text should be aligned horizontally.
final
textDirection TextDirection?
The directionality of the text.
final
textHeightBehavior TextHeightBehavior?
final
textScaler TextScaler
The font scaling strategy to use when laying out and rendering the text.
final

Methods

copyWith({Key? key, TextSpan? text, FCClear? clear, TextAlign? textAlign, TextDirection? textDirection, TextOverflow? overflow, double? textScaleFactor, TextScaler? textScaler, int? maxLines, Locale? locale, StrutStyle? strutStyle, TextHeightBehavior? textHeightBehavior, double? indent, EdgeInsetsGeometry? margin, EdgeInsetsGeometry? padding}) WrappableText
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.
override