Expand description
Text elements: text
, tspan
, tref
.
Modules
- Constants with Unicode’s directional formatting characters
Structs
- Unicode control characters to be inserted when
unicode-bidi
is specified. - In SVG text elements, we use
Chars
to store character data. For example, an element like<text>Foo Bar</text>
will be aText
with a single child, and the child will be aChars
with “Foo Bar” for its contents. - Chunk 🔒An absolutely-positioned array of
Span
s - The state of a text layout operation.
- A laid-out and resolved text span.
- Use as
PangoUnits::from_pixels()
so that we can check for overflow. - Span 🔒
Functions
- Adds Pango attributes, suitable for a span of text, to an
AttrList
. - Walks the children of a
<text>
,<tspan>
, or<tref>
element and appends chunks/spans from them into the specifiedchunks
array. - Returns
None
if the layout would be invalid due to, for example, out-of-bounds font sizes. - Computes the (x, y) offsets to be applied to spans after applying the text-anchor property (start, middle, end).
- Prepends and appends Unicode directional formatting characters.