Struct fit_text::BasicGlyphs[][src]

pub struct BasicGlyphs<'f> { /* fields omitted */ }
Expand description

A basic implementor for CharacterWidthCache

Implementations

Loads a Glyphs from an array of font data.

Loads a Glyphs from a Font.

Trait Implementations

Get the width of a character at a font size

Get the width of a string at a font_size

Split a string into a list of lines of text with the given format where no line is wider than the given max width. Newlines (\n) in the string are respected Read more

Get the width of the widest line after performing the calculation of CharacterWidthCache::format_lines Read more

Calculate a set of positioned lines of text with the given format that fit within the given rectangle Read more

Calculate a set of positioned text and metadata lines with the given format that fit within the given rectangle Read more

Check if text with the given format fits within a rectangle’s width

Check if text with the given format fits within a rectangle’s height

Check if text with the given format fits within a rectangle

Determine the maximum font size for text with the given format that will still allow the text to fit within a rectangle Read more

Determine the minumum height for a rectangle such that text with the given format will still fit within the rectangle Read more

Determine the minumum width for a rectangle such that text with the given format will still fit within the rectangle Read more

Determine the correct text size based on the given TextFormat

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.