Face

Struct Face 

Source
pub struct Face<'a> { /* private fields */ }

Implementations§

Source§

impl<'a> Face<'a>

Source

pub unsafe fn from_raw(library_raw: FT_Library, raw: FT_Face) -> Self

Source

pub fn attach_file(&self, filepathname: &str) -> FtResult<()>

Source

pub fn reference(&self) -> FtResult<()>

Source

pub fn set_char_size( &self, char_width: isize, char_height: isize, horz_resolution: u32, vert_resolution: u32, ) -> FtResult<()>

Source

pub fn set_pixel_sizes( &self, pixel_width: u32, pixel_height: u32, ) -> FtResult<()>

Source

pub fn load_glyph(&self, glyph_index: u32, load_flags: LoadFlag) -> FtResult<()>

Source

pub fn load_char(&self, char_code: usize, load_flags: LoadFlag) -> FtResult<()>

Source

pub fn set_transform(&self, matrix: &mut Matrix, delta: &mut Vector)

Source

pub fn get_char_index(&self, charcode: usize) -> u32

Source

pub fn get_kerning( &self, left_char_index: u32, right_char_index: u32, kern_mode: KerningMode, ) -> FtResult<Vector>

Source

pub fn glyph(&self) -> &GlyphSlot

Source

pub fn has_horizontal(&self) -> bool

Source

pub fn has_vertical(&self) -> bool

Source

pub fn has_kerning(&self) -> bool

Source

pub fn is_scalable(&self) -> bool

Source

pub fn is_sfnt(&self) -> bool

Source

pub fn is_fixed_width(&self) -> bool

Source

pub fn has_fixed_sizes(&self) -> bool

Source

pub fn has_glyph_names(&self) -> bool

Source

pub fn is_cid_keyed(&self) -> bool

Source

pub fn is_tricky(&self) -> bool

Source

pub fn has_color(&self) -> bool

Source

pub fn raw(&self) -> &FT_FaceRec

Source

pub fn raw_mut(&mut self) -> &mut FT_FaceRec

Source

pub fn ascender(&self) -> FT_Short

Source

pub fn descender(&self) -> FT_Short

Source

pub fn em_size(&self) -> FT_Short

Source

pub fn height(&self) -> FT_Short

Source

pub fn max_advance_width(&self) -> FT_Short

Source

pub fn max_advance_height(&self) -> FT_Short

Source

pub fn underline_position(&self) -> FT_Short

Source

pub fn underline_thickness(&self) -> FT_Short

Source

pub fn num_faces(&self) -> i16

Source

pub fn family_name(&self) -> Option<&Nul<u8>>

Source

pub fn style_name(&self) -> Option<&Nul<u8>>

Source

pub fn style_flags(&self) -> StyleFlag

Source

pub fn size_metrics(&self) -> Option<FT_Size_Metrics>

Source

pub fn postscript_name(&self) -> Option<&Nul<u8>>

Trait Implementations§

Source§

impl<'a> Debug for Face<'a>

Source§

fn fmt(&self, form: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'a> Drop for Face<'a>

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more
Source§

impl<'a> Hash for Face<'a>

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl<'a> PartialEq for Face<'a>

Source§

fn eq(&self, other: &Face<'a>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<'a> TryClone for Face<'a>

Source§

type Error = Error

Source§

fn try_clone(&self) -> FtResult<Self>

Source§

fn try_clone_from(&mut self, other: &Self) -> Result<(), Self::Error>

Source§

impl<'a> Eq for Face<'a>

Source§

impl<'a> StructuralPartialEq for Face<'a>

Auto Trait Implementations§

§

impl<'a> Freeze for Face<'a>

§

impl<'a> RefUnwindSafe for Face<'a>

§

impl<'a> !Send for Face<'a>

§

impl<'a> !Sync for Face<'a>

§

impl<'a> Unpin for Face<'a>

§

impl<'a> UnwindSafe for Face<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.