Skip to content

Commit

Permalink
Update ttf-parser to 0.17
Browse files Browse the repository at this point in the history
  • Loading branch information
alexheretic committed Sep 28, 2022
1 parent 5b06555 commit 3ae5c70
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions glyph/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Unreleased (0.2.18)
* Update _ttf-parser_ to `0.17`.

# 0.2.17
* Add `VariableFont` trait implemented by `FontRef` & `FontVec`.
Provides `variations` & `set_variation` functions.
Expand Down
2 changes: 1 addition & 1 deletion glyph/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ license = "Apache-2.0"
readme = "README.md"

[dependencies]
owned_ttf_parser = { version = "0.15.2", default-features = false }
owned_ttf_parser = { version = "0.17", default-features = false }
ab_glyph_rasterizer = { version = "0.1.2", path = "../rasterizer", default-features = false }
# no_std float stuff
# renamed to enable a "libm" feature
Expand Down
2 changes: 1 addition & 1 deletion glyph/src/ttfp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ impl<'font> FontRef<'font> {
#[inline]
pub fn try_from_slice_and_index(data: &'font [u8], index: u32) -> Result<Self, InvalidFont> {
Ok(Self(ttfp::PreParsedSubtables::from(
ttfp::Face::from_slice(data, index).map_err(|_| InvalidFont)?,
ttfp::Face::parse(data, index).map_err(|_| InvalidFont)?,
)))
}
}
Expand Down

0 comments on commit 3ae5c70

Please sign in to comment.