pub struct RemoteImageProps {
pub bytes: Option<Arc<Vec<u8>>>,
pub clip: Clip,
pub mode: ContentMode,
pub placeholder: Color,
}Expand description
Full props (realize). bytes seeds the view; all four are applied at build. Only bytes changes
after build, via RemoteImagePatch::SetBytes.
Fields§
§bytes: Option<Arc<Vec<u8>>>The initial encoded (PNG/JPEG) image bytes, or None for the placeholder.
clip: ClipClip shape for both the image and the placeholder.
mode: ContentModeAspect scaling of the decoded image within the frame.
placeholder: ColorFill color shown while bytes is None or on decode failure.
Trait Implementations§
Source§impl Clone for RemoteImageProps
impl Clone for RemoteImageProps
Source§fn clone(&self) -> RemoteImageProps
fn clone(&self) -> RemoteImageProps
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RemoteImageProps
impl Debug for RemoteImageProps
Source§impl Default for RemoteImageProps
impl Default for RemoteImageProps
Source§impl PartialEq for RemoteImageProps
impl PartialEq for RemoteImageProps
Source§fn eq(&self, other: &RemoteImageProps) -> bool
fn eq(&self, other: &RemoteImageProps) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for RemoteImageProps
Auto Trait Implementations§
impl Freeze for RemoteImageProps
impl RefUnwindSafe for RemoteImageProps
impl Send for RemoteImageProps
impl Sync for RemoteImageProps
impl Unpin for RemoteImageProps
impl UnsafeUnpin for RemoteImageProps
impl UnwindSafe for RemoteImageProps
Blanket Implementations§
§impl<T> AnyEq for T
impl<T> AnyEq for T
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<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more