pub struct GlyphKey {
pub font: FontId,
pub gid: Gid,
pub dest_width: i32,
pub weight: i32,
pub italic_angle: i32,
pub vertical: bool,
}Expand description
What identifies one cached outline.
hint_flags is deliberately absent, and stayed absent when wave 7b brought
hinting in. This cache holds the outlines the path side of text fills,
and that side is unhinted at every size, for every face.
The hinted outline belongs to the glyph-bitmap side, which is a different
cache in a different crate (pdfrum_render::glyph::BitmapCache) because it
holds a different thing: a rasterization, which depends on the device
matrix, where an outline does not. That separation is why this key did not
need to grow a size — the key that does have one is over there.
The five fields below all genuinely vary an outline for at least one face kind.
Fields§
§font: FontIdWhich font — cache entries from two fonts must never be confused even when they share a face.
gid: GidWhich glyph.
dest_width: i32The PDF’s declared width for this character code, which solves a Multiple-Master face’s width axis.
weight: i32The substitution weight, which drives a Multiple-Master face’s weight axis. Zero means the face’s own.
italic_angle: i32The synthetic italic angle, which shears the outline.
vertical: boolWhether this is a vertical-writing form.