#[repr(C)]pub struct GlyphPosition {
pub x_advance: i32,
pub y_advance: i32,
pub x_offset: i32,
pub y_offset: i32,
pub(crate) var: u32,
}Expand description
The advances and offsets of a shaped glyph.
Values use the scale of the shaping font. Offsets move a glyph relative to the current point without changing the position of the next glyph.
Fields§
§x_advance: i32Horizontal advance after drawing this glyph.
y_advance: i32Vertical advance after drawing this glyph.
x_offset: i32Horizontal offset from the current point.
y_offset: i32Vertical offset from the current point.
var: u32Implementations§
Source§impl GlyphPosition
impl GlyphPosition
pub(crate) fn attach_chain(&self) -> i16
pub(crate) fn set_attach_chain(&mut self, n: i16)
pub(crate) fn attach_type(&self) -> u8
pub(crate) fn set_attach_type(&mut self, n: u8)
Trait Implementations§
Source§impl Clone for GlyphPosition
impl Clone for GlyphPosition
Source§fn clone(&self) -> GlyphPosition
fn clone(&self) -> GlyphPosition
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for GlyphPosition
Source§impl Debug for GlyphPosition
impl Debug for GlyphPosition
Source§impl Default for GlyphPosition
impl Default for GlyphPosition
Source§fn default() -> GlyphPosition
fn default() -> GlyphPosition
Returns the “default value” for a type. Read more
impl Pod for GlyphPosition
Auto Trait Implementations§
impl Freeze for GlyphPosition
impl RefUnwindSafe for GlyphPosition
impl Send for GlyphPosition
impl Sync for GlyphPosition
impl Unpin for GlyphPosition
impl UnsafeUnpin for GlyphPosition
impl UnwindSafe for GlyphPosition
Blanket Implementations§
impl<T> AnyBitPattern for Twhere
T: Pod,
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
Source§impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
Source§type Bits = T
type Bits = T
Self must have the same layout as the specified Bits except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern.Source§fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
If this function returns true, then it must be valid to reinterpret
bits
as &Self.