Skip to main content

embedded_graphics_profont/
lib.rs

1#![no_std]
2#![doc = include_str!("../README.md")]
3
4//! # embedded-graphics-profont
5//!
6//! A lightweight bitmap font rendering library for `embedded-graphics`.
7//!
8//! ## Quick Start
9//!
10//! ```ignore
11//! use embedded_graphics::geometry::Point;
12//! use embedded_graphics_profont::{Font, Text, Anchor};
13//!
14//! // Create a font from pre-compiled bitmap data
15//! let font = Font::new(&LOOKUP_TABLE, &FONT_DATA, 32, 126, 8, true);
16//!
17//! // Render text with center anchor
18//! let text = Text::new("Hello", Point::new(64, 32), &font, color)
19//!     .with_anchor(Anchor::MiddleCenter);
20//! target.draw(&text)?;
21//! ```
22
23pub mod font;
24pub mod renderer;
25
26pub use font::{Anchor, Character, Font, GlyphEntry, Text, WithAnchor};