pub struct ActionRingLayout {
pub slots: BTreeMap<ActionRingSlot, ActionRingEntry>,
}Expand description
The actions displayed at the eight fixed ring positions.
Fields§
§slots: BTreeMap<ActionRingSlot, ActionRingEntry>Populated ring positions. An absent key is an intentionally empty slot.
Implementations§
Source§impl ActionRingLayout
impl ActionRingLayout
Sourcepub fn set_action(&mut self, slot: ActionRingSlot, action: Option<RingAction>)
pub fn set_action(&mut self, slot: ActionRingSlot, action: Option<RingAction>)
Replace or clear a slot while preserving its custom icon when replaced.
Sourcepub fn set_icon(&mut self, slot: ActionRingSlot, icon: Option<ActionRingIcon>)
pub fn set_icon(&mut self, slot: ActionRingSlot, icon: Option<ActionRingIcon>)
Set a custom icon for a populated slot. Empty slots remain empty.
Sourcepub fn set_label(&mut self, slot: ActionRingSlot, label: Option<String>)
pub fn set_label(&mut self, slot: ActionRingSlot, label: Option<String>)
Set a custom label for a populated slot. Empty slots remain empty.
Trait Implementations§
Source§impl Clone for ActionRingLayout
impl Clone for ActionRingLayout
Source§fn clone(&self) -> ActionRingLayout
fn clone(&self) -> ActionRingLayout
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 ActionRingLayout
impl Debug for ActionRingLayout
Source§impl Default for ActionRingLayout
impl Default for ActionRingLayout
Source§impl<'de> Deserialize<'de> for ActionRingLayout
impl<'de> Deserialize<'de> for ActionRingLayout
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for ActionRingLayout
Source§impl PartialEq for ActionRingLayout
impl PartialEq for ActionRingLayout
Source§impl Serialize for ActionRingLayout
impl Serialize for ActionRingLayout
impl StructuralPartialEq for ActionRingLayout
Auto Trait Implementations§
impl Freeze for ActionRingLayout
impl RefUnwindSafe for ActionRingLayout
impl Send for ActionRingLayout
impl Sync for ActionRingLayout
impl Unpin for ActionRingLayout
impl UnsafeUnpin for ActionRingLayout
impl UnwindSafe for ActionRingLayout
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.