Struct allsorts::bitmap::BitmapGlyph
source · [−]pub struct BitmapGlyph {
pub ppem_x: Option<u16>,
pub ppem_y: Option<u16>,
pub metrics: Metrics,
pub bitmap: Bitmap,
}
Expand description
A bitmap glyph with metrics.
Fields
ppem_x: Option<u16>
Horizontal pixels per em.
Will be None
if image data is a vector image.
ppem_y: Option<u16>
Vertical pixels per em.
Will be None
if image data is a vector image.
metrics: Metrics
Glyph metrics in pixels.
bitmap: Bitmap
Bitmap data.
Trait Implementations
sourceimpl<'a> From<(&SbixStrike<'a>, &SbixGlyph<'a>)> for BitmapGlyph
impl<'a> From<(&SbixStrike<'a>, &SbixGlyph<'a>)> for BitmapGlyph
sourcefn from((strike, glyph): (&SbixStrike<'a>, &SbixGlyph<'a>)) -> Self
fn from((strike, glyph): (&SbixStrike<'a>, &SbixGlyph<'a>)) -> Self
Converts to this type from the input type.
sourceimpl<'a> TryFrom<&SVGDocumentRecord<'a>> for BitmapGlyph
impl<'a> TryFrom<&SVGDocumentRecord<'a>> for BitmapGlyph
type Error = ParseError
type Error = ParseError
The type returned in the event of a conversion error.
sourcefn try_from(svg_record: &SVGDocumentRecord<'a>) -> Result<Self, ParseError>
fn try_from(svg_record: &SVGDocumentRecord<'a>) -> Result<Self, ParseError>
Performs the conversion.
sourceimpl<'a> TryFrom<(&BitmapInfo, GlyphBitmapData<'a>)> for BitmapGlyph
impl<'a> TryFrom<(&BitmapInfo, GlyphBitmapData<'a>)> for BitmapGlyph
type Error = ParseError
type Error = ParseError
The type returned in the event of a conversion error.
sourcefn try_from(
(info, glyph): (&BitmapInfo, GlyphBitmapData<'a>)
) -> Result<Self, Self::Error>
fn try_from(
(info, glyph): (&BitmapInfo, GlyphBitmapData<'a>)
) -> Result<Self, Self::Error>
Performs the conversion.
Auto Trait Implementations
impl RefUnwindSafe for BitmapGlyph
impl Send for BitmapGlyph
impl Sync for BitmapGlyph
impl Unpin for BitmapGlyph
impl UnwindSafe for BitmapGlyph
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more