Struct freya_engine::prelude::LocalResourceProvider
pub struct LocalResourceProvider { /* private fields */ }
Expand description
A resource provider that loads only local / inline base64 resources.
Implementations§
§impl LocalResourceProvider
impl LocalResourceProvider
pub fn new(font_mgr: impl Into<RCHandle<SkFontMgr>>) -> LocalResourceProvider
Trait Implementations§
§impl Debug for LocalResourceProvider
impl Debug for LocalResourceProvider
§impl ResourceProvider for LocalResourceProvider
impl ResourceProvider for LocalResourceProvider
fn load( &self, resource_path: &str, resource_name: &str, ) -> Option<RCHandle<SkData>>
fn load_typeface(&self, name: &str, url: &str) -> Option<RCHandle<SkTypeface>>
§fn font_mgr(&self) -> RCHandle<SkFontMgr>
fn font_mgr(&self) -> RCHandle<SkFontMgr>
This is used in the SVG Dom and should be used for ipmlementing load_typeface().
fn load_image_asset( &self, resource_path: &str, resource_name: &str, _resource_id: &str, ) -> Option<RCHandle<skresources_ImageAsset>>
Auto Trait Implementations§
impl Freeze for LocalResourceProvider
impl RefUnwindSafe for LocalResourceProvider
impl !Send for LocalResourceProvider
impl !Sync for LocalResourceProvider
impl Unpin for LocalResourceProvider
impl UnwindSafe for LocalResourceProvider
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