pub fn find_glyph_metrics(&self, ch: char) -> Option<GlyphMetrics> {
        let minx = 0;
        let maxx = 0;
        let miny = 0;
        let maxy = 0;
        let advance = 0;
        let ret = unsafe {
            ttf::TTF_GlyphMetrics(
                self.raw,
                ch as u16,
                &minx as *const _ as *mut _,
                &maxx as *const _ as *mut _,
                &miny as *const _ as *mut _,
                &maxy as *const _ as *mut _,
                &advance as *const _ as *mut _,
            )
        };
        if ret == 0 {
            Some(GlyphMetrics {
                minx: minx as i32,
                maxx: maxx as i32,
                miny: miny as i32,
                maxy: maxy as i32,
                advance: advance as i32,
            })
        } else {
            None
        }
    }
/// Returns the glyph metrics of the given character in this font face.
Returns the glyph metrics of the given character in this font face.
Returns the glyph metrics of the given character in this font face .
pub fn find_glyph_metrics(&self, ch: char) -> Option<GlyphMetrics> {
        let minx = 0;
        let maxx = 0;
        let miny = 0;
        let maxy = 0;
        let advance = 0;
        let ret = unsafe {
            ttf::TTF_GlyphMetrics(
                self.raw,
                ch as u16,
                &minx as *const _ as *mut _,
                &maxx as *const _ as *mut _,
                &miny as *const _ as *mut _,
                &maxy as *const _ as *mut _,
                &advance as *const _ as *mut _,
            )
        };
        if ret == 0 {
            Some(GlyphMetrics {
                minx: minx as i32,
                maxx: maxx as i32,
                miny: miny as i32,
                maxy: maxy as i32,
                advance: advance as i32,
            })
        } else {
            None
        }
    }
pub fn find_glyph_metrics ( & self , ch : char ) -> Option < GlyphMetrics > { let minx = 0 ; let maxx = 0 ; let miny = 0 ; let maxy = 0 ; let advance = 0 ; let ret = unsafe { ttf :: TTF_GlyphMetrics ( self . raw , ch as u16 , & minx as * const _ as * mut _ , & maxx as * const _ as * mut _ , & miny as * const _ as * mut _ , & maxy as * const _ as * mut _ , & advance as * const _ as * mut _ , ) } ; if ret == 0 { Some ( GlyphMetrics { minx : minx as i32 , maxx : maxx as i32 , miny : miny as i32 , maxy : maxy as i32 , advance : advance as i32 , } ) } else { None } }
Returns the glyph metrics of the given character in this font face.
Returns the glyph metrics of the given character in this font face .
&self
ch
char
&self
ch
char