RenderTextMixin mixin

Mix this into classes that should mirror the functionality of RenderParagraph.

Mixin applications

Properties

hashCode int
The hash code for this object.
no setterinherited
height double
The vertical space required to paint the text.
no setter
locale Locale?
Used by this paragraph's internal TextPainter to select a locale-specific font.
no setter
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 and softWrap.
no setter
offset Offset
The offset of the text in the render box.
no setter
renderBox RenderBox
The render box containing this text.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
softWrap bool
Whether the text should break at soft line breaks.
no setter
strutStyle StrutStyle?
The strut style to use. Strut style defines the strut, which sets minimum vertical layout metrics.
no setter
text InlineSpan
The text to display.
no setter
textAlign TextAlign
How the text should be aligned horizontally.
no setter
textDirection TextDirection
The directionality of the text.
no setter
textHeightBehavior TextHeightBehavior?
Defines how to apply TextStyle.height over and under text.
no setter
textScaleFactor double
Deprecated. Will be removed in a future version of Flutter. Use textScaler instead.
no setter
textScaler TextScaler
The font scaling strategy to use when laying out and rendering the text.
no setter
textSize Size
Returns the size of the text as laid out.
no setter
textWidthBasis TextWidthBasis
Defines how to measure the width of the rendered text.
no setter
width double
The horizontal space required to paint the text.
no setter

Methods

getBoxesForSelection(TextSelection selection, {BoxHeightStyle boxHeightStyle = ui.BoxHeightStyle.tight, BoxWidthStyle boxWidthStyle = ui.BoxWidthStyle.tight}) List<TextBox>
Returns a list of rects that bound the given selection.
getFullHeightForCaret(TextPosition position) double?
Returns the strut bounded height of the glyph at the given position.
getOffsetForCaret(TextPosition position, Rect caretPrototype) Offset
Returns the offset at which to paint the caret.
getPositionForOffset(Offset offset) TextPosition
Returns the position within the text for the given pixel offset.
getWordBoundary(TextPosition position) TextRange
Returns the text range of the word at the given offset. Characters not part of a word, such as spaces, symbols, and punctuation, have word breaks on both sides. In such cases, this method will return a text range that contains the given text position.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
paint(PaintingContext context, Offset offset) → void
Paints the text in the given context at the given offset.
toString() String
A string representation of this object.
inherited

Operators

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