#font #ttf #truetype #glow #text

glow_glyph

A fast text renderer for glow, powered by glyph_brush

7 releases (breaking)

0.5.0 Dec 17, 2021
0.4.0 Nov 10, 2020
0.3.0 Jul 27, 2020
0.2.1 Jun 27, 2020
0.0.0 May 21, 2020

#10 in Visualization

Download history 917/week @ 2021-10-01 762/week @ 2021-10-08 988/week @ 2021-10-15 939/week @ 2021-10-22 1485/week @ 2021-10-29 1071/week @ 2021-11-05 1210/week @ 2021-11-12 803/week @ 2021-11-19 707/week @ 2021-11-26 1323/week @ 2021-12-03 552/week @ 2021-12-10 448/week @ 2021-12-17 313/week @ 2021-12-24 726/week @ 2021-12-31 698/week @ 2022-01-07 781/week @ 2022-01-14

2,559 downloads per month
Used in 11 crates (via iced_glow)

MIT license

75KB
1.5K SLoC

glow_glyph

Integration status crates.io Documentation License

A fast text renderer for glow, powered by glyph_brush

use glow_glyph::{Section, GlyphBrushBuilder};

let font: &[u8] = include_bytes!("SomeFont.ttf");
let mut glyph_brush = GlyphBrushBuilder::using_font_bytes(font)
    .expect("Load font")
    .build(&glow_context);

let section = Section {
    text: "Hello glow_glyph",
    ..Section::default() // color, position, etc
};

glyph_brush.queue(section);
glyph_brush.queue(some_other_section);

glyph_brush.draw_queued(
    &glow_context,
    window_width,
    window_height,
);

Examples

Have a look at

  • cargo run --example hello
  • cargo run --example clipping

Dependencies

~3–5MB
~101K SLoC