pango::prelude

Trait FontsetExt

Source
pub trait FontsetExt:
    IsA<Fontset>
    + Sealed
    + 'static {
    // Provided methods
    fn foreach<P: FnMut(&Fontset, &Font) -> bool>(&self, func: P) { ... }
    fn font(&self, wc: u32) -> Font { ... }
    fn metrics(&self) -> FontMetrics { ... }
}
Expand description

Trait containing all Fontset methods.

§Implementors

FontsetSimple, Fontset

Provided Methods§

Source

fn foreach<P: FnMut(&Fontset, &Font) -> bool>(&self, func: P)

Iterates through all the fonts in a fontset, calling @func for each one.

If @func returns true, that stops the iteration.

§func

Callback function

Source

fn font(&self, wc: u32) -> Font

Returns the font in the fontset that contains the best glyph for a Unicode character.

§wc

a Unicode character

§Returns

a Font

Source

fn metrics(&self) -> FontMetrics

Get overall metric information for the fonts in the fontset.

§Returns

a FontMetrics object

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§