pub struct ImageDecor {
pub badge: Option<Badge>,
pub border: Option<ImageBorder>,
pub watermark: Option<Watermark>,
pub radius: f32,
pub shadow: Option<Shadow>,
}Expand description
图片装饰层 —— 叠在图面上的附加呈现,不改变布局尺寸(阴影溢出照画)。
Fields§
§badge: Option<Badge>角标:小标签贴在图的一角(如「动图」「GIF」)。
border: Option<ImageBorder>边框:沿图片边缘描边(圆角时随圆角走)。
watermark: Option<Watermark>水印:半透明文字叠在图面。
radius: f32圆角半径(逻辑像素,0 = 直角):裁切图面,边框/阴影随之。
shadow: Option<Shadow>投影;None = 无。
Trait Implementations§
Source§impl Clone for ImageDecor
impl Clone for ImageDecor
Source§fn clone(&self) -> ImageDecor
fn clone(&self) -> ImageDecor
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 ImageDecor
impl Debug for ImageDecor
Source§impl Default for ImageDecor
impl Default for ImageDecor
Source§fn default() -> ImageDecor
fn default() -> ImageDecor
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ImageDecor
impl RefUnwindSafe for ImageDecor
impl Send for ImageDecor
impl Sync for ImageDecor
impl Unpin for ImageDecor
impl UnsafeUnpin for ImageDecor
impl UnwindSafe for ImageDecor
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