pub struct CustomRectConfig {
pub position_size_config: Option<PositionSizeConfig>,
pub clip_rect: Option<Option<PositionSizeConfig>>,
pub hidden: Option<bool>,
pub ignore_render_layer: Option<bool>,
pub rounding: Option<f32>,
pub color: Option<[u8; 3]>,
pub alpha: Option<u8>,
pub border_width: Option<f32>,
pub border_color: Option<[u8; 3]>,
pub border_alpha: Option<u8>,
pub border_kind: Option<BorderKind>,
pub tags: Option<Vec<[String; 2]>>,
}Expand description
矩形的可配置项。
Fields§
§position_size_config: Option<PositionSizeConfig>位置尺寸配置。
clip_rect: Option<Option<PositionSizeConfig>>允许渲染的范围。
隐藏。
ignore_render_layer: Option<bool>忽略渲染层级。
rounding: Option<f32>圆角。
color: Option<[u8; 3]>颜色。
alpha: Option<u8>不透明度。
border_width: Option<f32>边框宽度。
border_color: Option<[u8; 3]>边框颜色。
border_alpha: Option<u8>边框透明度。
border_kind: Option<BorderKind>边框类型。
标签。
Implementations§
Source§impl CustomRectConfig
impl CustomRectConfig
pub fn from_custom_rect(custom_rect: &CustomRect) -> Self
pub fn position_size_config( self, position_size_config: Option<PositionSizeConfig>, ) -> Self
pub fn clip_rect(self, clip_rect: Option<Option<PositionSizeConfig>>) -> Self
pub fn ignore_render_layer(self, ignore_render_layer: Option<bool>) -> Self
pub fn rounding(self, rounding: Option<f32>) -> Self
pub fn color(self, color: Option<[u8; 3]>) -> Self
pub fn alpha(self, alpha: Option<u8>) -> Self
pub fn border_width(self, border_width: Option<f32>) -> Self
pub fn border_color(self, border_color: Option<[u8; 3]>) -> Self
pub fn border_alpha(self, border_alpha: Option<u8>) -> Self
pub fn border_kind(self, border_kind: Option<BorderKind>) -> Self
Trait Implementations§
Source§impl Clone for CustomRectConfig
impl Clone for CustomRectConfig
Source§fn clone(&self) -> CustomRectConfig
fn clone(&self) -> CustomRectConfig
Returns a duplicate of the value. Read more
1.0.0 · 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 CustomRectConfig
impl Debug for CustomRectConfig
Source§impl Default for CustomRectConfig
impl Default for CustomRectConfig
Source§fn default() -> CustomRectConfig
fn default() -> CustomRectConfig
Returns the “default value” for a type. Read more
Source§impl PartialEq for CustomRectConfig
impl PartialEq for CustomRectConfig
Source§impl PartialOrd for CustomRectConfig
impl PartialOrd for CustomRectConfig
impl StructuralPartialEq for CustomRectConfig
Auto Trait Implementations§
impl Freeze for CustomRectConfig
impl RefUnwindSafe for CustomRectConfig
impl Send for CustomRectConfig
impl Sync for CustomRectConfig
impl Unpin for CustomRectConfig
impl UnsafeUnpin for CustomRectConfig
impl UnwindSafe for CustomRectConfig
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<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().