pangocairo::prelude

Trait PangoCairoFontMapExt

Source
pub trait PangoCairoFontMapExt:
    IsA<FontMap>
    + Sealed
    + 'static {
    // Provided methods
    fn resolution(&self) -> f64 { ... }
    fn set_resolution(&self, dpi: f64) { ... }
}
Expand description

Trait containing all FontMap methods.

§Implementors

FontMap

Provided Methods§

Source

fn resolution(&self) -> f64

Gets the resolution for the fontmap.

See set_resolution().

§Returns

the resolution in “dots per inch”

Source

fn set_resolution(&self, dpi: f64)

Sets the resolution for the fontmap.

This is a scale factor between points specified in a PangoFontDescription and Cairo units. The default value is 96, meaning that a 10 point font will be 13 units high. (10 * 96. / 72. = 13.3).

§dpi

the resolution in “dots per inch”. (Physical inches aren’t actually involved; the terminology is conventional.)

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§