pub struct PNGImage { /* private fields */ }Expand description
PNG image path wrapper.
Implementations§
Source§impl PNGImage
impl PNGImage
Sourcepub fn new(path: &str) -> Result<Self, CotisImageError>
pub fn new(path: &str) -> Result<Self, CotisImageError>
Creates a PNG image from a relative path.
§Errors
Returns:
CotisImageError::EmptyPathwhenpathis empty.CotisImageError::NotRelativePathwhenpathstarts with/.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PNGImage
impl RefUnwindSafe for PNGImage
impl Send for PNGImage
impl Sync for PNGImage
impl Unpin for PNGImage
impl UnsafeUnpin for PNGImage
impl UnwindSafe for PNGImage
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<H, TailTarget, Source, Idx> Embed<RenderTList<H, TailTarget>, There<Idx>> for Sourcewhere
TailTarget: IsRenderList,
Source: Embed<TailTarget, Idx>,
impl<H, TailTarget, Source, Idx> Embed<RenderTList<H, TailTarget>, There<Idx>> for Sourcewhere
TailTarget: IsRenderList,
Source: Embed<TailTarget, Idx>,
Source§fn embed(self) -> RenderTList<H, TailTarget>
fn embed(self) -> RenderTList<H, TailTarget>
Converts
self into Target.