#font

font

The package provides a font toolbox

21 unstable releases (3 breaking)

Uses old Rust 2015

0.3.2 Oct 28, 2016
0.3.1 Aug 27, 2016
0.2.1 Aug 23, 2016
0.1.1 Jul 30, 2016
0.0.1 Aug 13, 2015

#61 in Data formats

Download history 12/week @ 2020-06-09 31/week @ 2020-06-16 11/week @ 2020-06-23 32/week @ 2020-06-30 32/week @ 2020-07-07 53/week @ 2020-07-14 10/week @ 2020-07-21 11/week @ 2020-07-28 10/week @ 2020-08-04 86/week @ 2020-08-11 48/week @ 2020-08-18 51/week @ 2020-08-25 72/week @ 2020-09-01 66/week @ 2020-09-08 28/week @ 2020-09-15 21/week @ 2020-09-22

171 downloads per month
Used in 2 crates

Apache-2.0/MIT

31KB
802 lines

Font Version Status

The package provides a font toolbox.

Documentation

Example

use font::{Font, Segment};

let path = "SourceSerifPro-Regular.otf";
let font = Font::open(path).unwrap();
let glyph = font.draw('&').unwrap().unwrap();
for contour in glyph.iter() {
    for segment in contour.iter() {
        match segment {
            &Segment::Linear(..) => { /**/ },
            &Segment::Quadratic(..) => { /**/ },
            &Segment::Cubic(..) => { /**/ },
        }
    }
}

Contribution

Your contribution is highly appreciated. Do not hesitate to open an issue or a pull request. Note that any contribution submitted for inclusion in the project will be licensed according to the terms given in LICENSE.md.

Dependencies

~275KB