Struct rat_widget::popup_menu::RPopupMenu
source · pub struct RPopupMenu<'a> { /* private fields */ }Expand description
Popup menu.
Implementations§
source§impl<'a> RPopupMenu<'a>
impl<'a> RPopupMenu<'a>
sourcepub fn add(self, item: Line<'a>, navchar: Option<char>) -> Self
pub fn add(self, item: Line<'a>, navchar: Option<char>) -> Self
Add a formatted item. The navchar is optional, any markup for it is your problem.
sourcepub fn width(self, width: u16) -> Self
pub fn width(self, width: u16) -> Self
Fixed width for the menu. If not set it uses 1.5 times the length of the longest item.
sourcepub fn focus_style(self, style: Style) -> Self
pub fn focus_style(self, style: Style) -> Self
Selection
Trait Implementations§
source§impl<'a> Clone for RPopupMenu<'a>
impl<'a> Clone for RPopupMenu<'a>
source§fn clone(&self) -> RPopupMenu<'a>
fn clone(&self) -> RPopupMenu<'a>
Returns a copy 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<'a> Debug for RPopupMenu<'a>
impl<'a> Debug for RPopupMenu<'a>
source§impl<'a> Default for RPopupMenu<'a>
impl<'a> Default for RPopupMenu<'a>
source§fn default() -> RPopupMenu<'a>
fn default() -> RPopupMenu<'a>
Returns the “default value” for a type. Read more
source§impl<'a> StatefulWidget for RPopupMenu<'a>
impl<'a> StatefulWidget for RPopupMenu<'a>
source§impl<'a> StatefulWidgetRef for RPopupMenu<'a>
impl<'a> StatefulWidgetRef for RPopupMenu<'a>
§type State = RPopupMenuState
type State = RPopupMenuState
State associated with the stateful widget. Read more
Auto Trait Implementations§
impl<'a> Freeze for RPopupMenu<'a>
impl<'a> RefUnwindSafe for RPopupMenu<'a>
impl<'a> Send for RPopupMenu<'a>
impl<'a> Sync for RPopupMenu<'a>
impl<'a> Unpin for RPopupMenu<'a>
impl<'a> UnwindSafe for RPopupMenu<'a>
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§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)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