[][src]Function azul_core::app_resources::build_add_font_resource_updates

pub fn build_add_font_resource_updates<T: FontImageApi>(
    app_resources: &AppResources,
    render_api: &mut T,
    pipeline_id: &PipelineId,
    fonts_in_dom: &FastHashMap<ImmediateFontId, FastHashSet<Au>>,
    font_source_load_fn: LoadFontFn
) -> Vec<(ImmediateFontId, AddFontMsg)>

Given the fonts of the current frame, returns AddFont and AddFontInstances of which fonts / instances are currently not in the current_registered_fonts and need to be added.

Deleting fonts can only be done after the entire frame has finished drawing, otherwise (if removing fonts would happen after every DOM) we'd constantly add-and-remove fonts after every IFrameCallback, which would cause a lot of I/O waiting.