pub struct ActionButton { /* private fields */ }Expand description
One action as a button of its own, for a screen that places its commands itself.
Implementations§
Source§impl ActionButton
impl ActionButton
Sourcepub fn new(session: Session, id: impl Into<String>) -> Self
pub fn new(session: Session, id: impl Into<String>) -> Self
The button of the action with this id.
Sourcepub fn style(self, style: ButtonStyle) -> Self
pub fn style(self, style: ButtonStyle) -> Self
How it looks.
Sourcepub fn size(self, size: ButtonSize) -> Self
pub fn size(self, size: ButtonSize) -> Self
How big it is. Small by default.
Sourcepub fn hide_when_off(self) -> Self
pub fn hide_when_off(self) -> Self
Takes it away while it cannot be used, instead of fading it. Only for a button at the end of a row of them, so nothing moves under the pointer.
Trait Implementations§
Source§impl Debug for ActionButton
impl Debug for ActionButton
Auto Trait Implementations§
impl !RefUnwindSafe for ActionButton
impl !Send for ActionButton
impl !Sync for ActionButton
impl !UnwindSafe for ActionButton
impl Freeze for ActionButton
impl Unpin for ActionButton
impl UnsafeUnpin for ActionButton
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
impl<T> ErasedDestructor for Twhere
T: 'static,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<V> ViewExt for Vwhere
V: View,
impl<V> ViewExt for Vwhere
V: View,
Source§fn padding(self, padding: impl Into<Insets>) -> Styled<Self>
fn padding(self, padding: impl Into<Insets>) -> Styled<Self>
Adds padding inside the box, in logical pixels.
Source§fn background(self, fill: impl Into<Fill>) -> Styled<Self>
fn background(self, fill: impl Into<Fill>) -> Styled<Self>
Paints a background behind the content.
Source§fn frame(self, width: Option<f32>, height: Option<f32>) -> Styled<Self>
fn frame(self, width: Option<f32>, height: Option<f32>) -> Styled<Self>
Fixes the width and/or height in logical pixels;
None keeps the content size.