UEpubTextStyler class abstract final

Builds the exact TextSpan a block is rendered with, so pagination, highlight painting and hit-testing all agree on the same layout.

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

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

Static Methods

align(UEpubBlock block, UEpubTypography typography) → TextAlign
Alignment of a block.
background(BuildContext context, UDocColorMode mode) → Color
Page color for a color mode.
direction(UEpubBlock block) → TextDirection
Text direction of a block (RTL for Persian).
foreground(BuildContext context, UDocColorMode mode) → Color
Text color for a color mode.
headingScale(int level) → double
Size factor of a heading level.
lineRects(TextPainter painter, String text, int start, int end, {required double fontSize}) → List<Rect>
One rectangle per visual line for [start, end), trimmed of the spaces at line wraps and shrunk from the full line height to the glyph band, so highlights look the same as in the PDF viewer.
painter(BuildContext context, UEpubBlock block, UEpubTypography typography, UDocColorMode mode, double width, {int start = 0, int end = -1}) → TextPainter
Text painter of a block (for measuring pages).
span(BuildContext context, UEpubBlock block, UEpubTypography typography, UDocColorMode mode, {int start = 0, int end = -1, void onLink(String href)?}) → TextSpan
Styled text of a block.