pub struct Glyph {
pub line_y: f32,
pub font_size: f32,
pub width: f32,
pub x: f32,
pub style: GlyphStyle,
}Expand description
A glyph to be rendered.
This corresponds to the LayoutGlyph type in cosmic-text and similar types in other text
renderers. Glyphs should be converted to this type before being passed to the line generator.
Fields§
§line_y: f32The y coordinate of the glyph’s line.
font_size: f32The font size of the glyph in pixels.
width: f32The width of the glyph’s bounding box.
x: f32The X coordinate of the glyph’s bounding box.
style: GlyphStyleThe style of the glyph.
Trait Implementations§
impl Copy for Glyph
impl StructuralPartialEq for Glyph
Auto Trait Implementations§
impl Freeze for Glyph
impl RefUnwindSafe for Glyph
impl Send for Glyph
impl Sync for Glyph
impl Unpin for Glyph
impl UnwindSafe for Glyph
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