Skip to content

Commit

Permalink
Doc nits
Browse files Browse the repository at this point in the history
  • Loading branch information
simoncozens committed Nov 27, 2024
1 parent 6722b0a commit 176cec5
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
2 changes: 1 addition & 1 deletion shaperglot-lib/src/checker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ use skrifa::{raw::ReadError, FontRef, GlyphId, MetadataProvider};

/// The context for running font language support checks
pub struct Checker<'a> {
/// The font to check, as a [read_fonts::FontRef]
/// The font to check, as a [skrifa::FontRef]
pub font: FontRef<'a>,
/// The face to use for shaping
pub face: Face<'a>,
Expand Down
15 changes: 15 additions & 0 deletions shaperglot-lib/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,21 @@
//! dictate particular implementations of language support, in terms of
//! what glyphs or rules are present in the font or how glyphs should be named,
//! but tests a font for its behaviour.
//!
//! # Example
//!
//! ```
//! use shaperglot::{Checker, Languages, Provider};
//!
//! fn test_font(font_binary: &[u8]) {
//! let font = Checker::new(font_binary).expect("Failed to load font");
//! let languages = Languages::new();
//! for language in languages.iter() {
//! let results = font.check(language);
//! println!("{}", results.to_summary_string(language));
//! }
//! }
//! ```
/// The checker object, representing the context of a check
mod checker;
Expand Down

0 comments on commit 176cec5

Please sign in to comment.