Struct nanovg::Font[][src]

pub struct Font<'a>(_, _);

A handle to a font. Fonts are managed by the NanoVG context itself. View this type only as a 'reference' to a font.

Methods

impl<'a> Font<'a>
[src]

Get the underlying context this font was created on.

Attempt to load a font from the file at path. Fonts are always named (specified with name).

Attempt to load a font from memory. Fonts are always named (specified with name).

Try to find a already loaded font with the given name.

Add fallback as a fallback for the current font. If the font renderer fails to rasterize a glyph with the main font, it will automatically attempt to rasterize the same glyph with the fallback font. This process continues until no working font is found, then the glyph is skipped.

Trait Implementations

impl<'a> Clone for Font<'a>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<'a> Copy for Font<'a>
[src]

impl<'a> Debug for Font<'a>
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl<'a> !Send for Font<'a>

impl<'a> !Sync for Font<'a>