pub enum Attr {
Show 23 variants
W(Units),
H(Units),
MinW(f32),
MinH(f32),
Flex(f32),
Gap(f32),
FontScale(f32),
Dock(Dock),
Align(Align),
FocusStyle(FocusStyle),
HAlign(HAlign),
VAlign(VAlign),
Padding([f32; 4]),
Margin([f32; 4]),
Bg(Color),
BgImage(String),
Color(Color),
FocusColor(Color),
Shadow(bool),
Enabled(bool),
NoWrap(bool),
Ellipsis(bool),
MaxLength(usize),
}Expand description
One attribute, its value read.
Variants§
W(Units)
H(Units)
MinW(f32)
MinH(f32)
Flex(f32)
Gap(f32)
FontScale(f32)
Dock(Dock)
Align(Align)
FocusStyle(FocusStyle)
HAlign(HAlign)
VAlign(VAlign)
Padding([f32; 4])
Margin([f32; 4])
Bg(Color)
BgImage(String)
An image as the background: sprite:panel, mymod:gui/frame.
Color(Color)
FocusColor(Color)
Shadow(bool)
Enabled(bool)
NoWrap(bool)
Ellipsis(bool)
MaxLength(usize)
Implementations§
Source§impl Attr
impl Attr
Sourcepub fn parse(key: &str, value: &str) -> Result<Option<Attr>, String>
pub fn parse(key: &str, value: &str) -> Result<Option<Attr>, String>
key="value" as an attribute; none when key isn’t one of these
(an id, an event, a text, a kind’s own); what’s wrong otherwise.
Trait Implementations§
impl StructuralPartialEq for Attr
Auto Trait Implementations§
impl Freeze for Attr
impl RefUnwindSafe for Attr
impl Send for Attr
impl Sync for Attr
impl Unpin for Attr
impl UnsafeUnpin for Attr
impl UnwindSafe for Attr
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