From 22036a0f9e3bae6c571e5c1d9d2ee2fbc9d8cd81 Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Tue, 25 Oct 2022 19:17:40 -0600 Subject: [PATCH] Font does not need to store index, it is part of info --- src/font/font.rs | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/font/font.rs b/src/font/font.rs index c9a3adc..5a6c77a 100644 --- a/src/font/font.rs +++ b/src/font/font.rs @@ -5,7 +5,6 @@ use std::ops::Deref; pub struct Font<'a> { pub info: &'a fontdb::FaceInfo, pub data: &'a [u8], - pub index: u32, pub rustybuzz: rustybuzz::Face<'a>, #[cfg(feature = "swash")] pub swash: (u32, swash::CacheKey), @@ -25,7 +24,6 @@ impl<'a> Font<'a> { Some(Self { info, data, - index: info.index, rustybuzz: rustybuzz::Face::from_slice(data, info.index)?, #[cfg(feature = "swash")] swash: {