Struct pdf::FontMetrics
[−]
[src]
pub struct FontMetrics { /* fields omitted */ }
Relevant data that can be loaded from an AFM (Adobe Font Metrics) file. A FontMetrics object is specific to a given encoding.
Methods
impl FontMetrics
[src]
fn parse(source: File) -> Result<FontMetrics>
Create a FontMetrics by reading an .afm file.
fn get_width(&self, char: u8) -> Option<u16>
Get the width of a specific character. The character is given in the encoding of the FontMetrics object.
Trait Implementations
impl Debug for FontMetrics
[src]
impl Hash for FontMetrics
[src]
fn hash<__H: Hasher>(&self, __arg_0: &mut __H)
Feeds this value into the state given, updating the hasher as necessary.
fn hash_slice<H>(data: &[Self], state: &mut H) where H: Hasher
1.3.0
Feeds a slice of this type into the state provided.
impl PartialEq for FontMetrics
[src]
fn eq(&self, __arg_0: &FontMetrics) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &FontMetrics) -> bool
This method tests for !=
.
impl Eq for FontMetrics
[src]
impl Clone for FontMetrics
[src]
fn clone(&self) -> FontMetrics
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more