Filter out whitespace glyphs from display list

Fixes #10244.
This commit is contained in:
Matt Brubeck 2016-05-05 09:28:44 -07:00
parent 15c5c81b1f
commit 0f221521ab
3 changed files with 26 additions and 18 deletions

View file

@ -109,6 +109,7 @@ impl GlyphEntry {
Au(((self.value & GLYPH_ADVANCE_MASK) >> GLYPH_ADVANCE_SHIFT) as i32)
}
#[inline]
fn id(&self) -> GlyphId {
self.value & GLYPH_ID_MASK
}
@ -361,6 +362,7 @@ impl<'a> GlyphInfo<'a> {
}
}
#[inline]
pub fn offset(self) -> Option<Point2D<Au>> {
match self {
GlyphInfo::Simple(_, _) => None,
@ -436,10 +438,12 @@ impl<'a> GlyphStore {
}
}
#[inline]
pub fn len(&self) -> ByteIndex {
ByteIndex(self.entry_buffer.len() as isize)
}
#[inline]
pub fn is_whitespace(&self) -> bool {
self.is_whitespace
}