pub fn load_device_font<'gc>(
        gc_context: gc_arena::MutationContext<'gc, '_>,
        data: &[u8],
        renderer: &mut dyn RenderBackend,
    ) -> Result<crate::font::Font<'gc>, Error> {
        let mut reader = swf::read::Reader::new(data, 8);
        let device_font = crate::font::Font::from_swf_tag(
            gc_context,
            renderer,
            reader.read_define_font_2(3)?,
            reader.encoding(),
        )?;
        Ok(device_font)
    }
/// Loads font data from the given buffer.
/// The buffer should be the `DefineFont3` info for the tag.
/// The tag header should not be included.
Loads font data from the given buffer.
The buffer should be the `DefineFont3` info for the tag.
The tag header should not be included.
Loads font data from the given buffer . The buffer should be the ` DefineFont3 ` info for the tag . The tag header should not be included .
pub fn load_device_font<'gc>(
        gc_context: gc_arena::MutationContext<'gc, '_>,
        data: &[u8],
        renderer: &mut dyn RenderBackend,
    ) -> Result<crate::font::Font<'gc>, Error> {
        let mut reader = swf::read::Reader::new(data, 8);
        let device_font = crate::font::Font::from_swf_tag(
            gc_context,
            renderer,
            reader.read_define_font_2(3)?,
            reader.encoding(),
        )?;
        Ok(device_font)
    }
pub fn load_device_font < ' gc > ( gc_context : gc_arena :: MutationContext < ' gc , ' _ > , data : & [ u8 ] , renderer : & mut dyn RenderBackend , ) -> Result < crate :: font :: Font < ' gc > , Error > { let mut reader = swf :: read :: Reader :: new ( data , 8 ) ; let device_font = crate :: font :: Font :: from_swf_tag ( gc_context , renderer , reader . read_define_font_2 ( 3 ) ? , reader . encoding ( ) , ) ? ; Ok ( device_font ) }
Loads font data from the given buffer.
Loads font data from the given buffer .
gc_context
gc_arena::MutationContext<'gc, '_>
data
&[u8]
renderer
&mut dyn RenderBackend
gc_context
gc_arena::MutationContext<'gc, '_>
data
&[u8]
renderer
&mut dyn RenderBackend