pub struct FontWriter { /* private fields */ }Expand description
Helper struct for writing TTF data with proper endianness handling
Implementations§
Source§impl FontWriter
impl FontWriter
pub fn new() -> Self
pub fn with_capacity(capacity: usize) -> Self
pub fn position(&self) -> usize
pub fn into_inner(self) -> Vec<u8> ⓘ
pub fn as_slice(&self) -> &[u8] ⓘ
pub fn write_u8(&mut self, val: u8)
pub fn write_i8(&mut self, val: i8)
pub fn write_u16(&mut self, val: u16)
pub fn write_i16(&mut self, val: i16)
pub fn write_u24(&mut self, val: u32)
pub fn write_u32(&mut self, val: u32)
pub fn write_i32(&mut self, val: i32)
pub fn write_u64(&mut self, val: u64)
pub fn write_i64(&mut self, val: i64)
pub fn write_fixed(&mut self, val: f32)
pub fn write_f2dot14(&mut self, val: f32)
pub fn write_long_datetime(&mut self, val: u64)
pub fn write_tag(&mut self, tag: &[u8; 4])
pub fn write_bytes(&mut self, bytes: &[u8])
pub fn write_padding(&mut self, align: usize)
pub fn pad_to(&mut self, target_len: usize)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for FontWriter
impl RefUnwindSafe for FontWriter
impl Send for FontWriter
impl Sync for FontWriter
impl Unpin for FontWriter
impl UnwindSafe for FontWriter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more