Trait font_types::Scalar

source ·
pub trait Scalar {
    type Raw: Copy + AsRef<[u8]>;

    fn from_raw(raw: Self::Raw) -> Self;
    fn to_raw(self) -> Self::Raw;
}
Expand description

A trait for font scalars.

This is an internal trait for encoding and decoding big-endian bytes.

You do not need to implement this trait directly; it is an implemention detail of the BigEndian wrapper.

Required Associated Types§

The raw byte representation of this type.

Required Methods§

Create an instance of this type from raw big-endian bytes

Encode this type as raw big-endian bytes

Implementations on Foreign Types§

Implementors§