pub struct GlyphDefinition {
pub labels: Vec<Label>,
pub bitmap: Bitmap,
pub left_bearing: Option<i32>,
pub right_bearing: Option<i32>,
pub shift_up: Option<i32>,
pub top_bearing: Option<i32>,
pub bottom_bearing: Option<i32>,
pub shift_left: Option<i32>,
pub right_kerning: Option<HashMap<Label, f32>>,
pub left_kerning: Option<HashMap<Label, f32>>,
pub scalable_width: Option<f32>,
}Expand description
A single glyph definition including bitmap data and typography metrics.
Each glyph can have multiple labels (Unicode codepoints, legacy encodings, or tags) and includes bitmap pixel data plus optional bearing and kerning information.
Fields§
§labels: Vec<Label>§bitmap: Bitmap§left_bearing: Option<i32>§right_bearing: Option<i32>§shift_up: Option<i32>§top_bearing: Option<i32>§bottom_bearing: Option<i32>§shift_left: Option<i32>§right_kerning: Option<HashMap<Label, f32>>§left_kerning: Option<HashMap<Label, f32>>§scalable_width: Option<f32>Trait Implementations§
Source§impl Clone for GlyphDefinition
impl Clone for GlyphDefinition
Source§fn clone(&self) -> GlyphDefinition
fn clone(&self) -> GlyphDefinition
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for GlyphDefinition
impl Debug for GlyphDefinition
Source§impl Default for GlyphDefinition
impl Default for GlyphDefinition
Source§fn default() -> GlyphDefinition
fn default() -> GlyphDefinition
Returns the “default value” for a type. Read more
Source§impl PartialEq for GlyphDefinition
impl PartialEq for GlyphDefinition
impl StructuralPartialEq for GlyphDefinition
Auto Trait Implementations§
impl Freeze for GlyphDefinition
impl RefUnwindSafe for GlyphDefinition
impl Send for GlyphDefinition
impl Sync for GlyphDefinition
impl Unpin for GlyphDefinition
impl UnwindSafe for GlyphDefinition
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more