Struct gdk::ModifierType
source · [−]pub struct ModifierType { /* private fields */ }Implementations
sourceimpl ModifierType
impl ModifierType
pub const SHIFT_MASK: ModifierType = _
pub const LOCK_MASK: ModifierType = _
pub const CONTROL_MASK: ModifierType = _
pub const MOD1_MASK: ModifierType = _
pub const MOD2_MASK: ModifierType = _
pub const MOD3_MASK: ModifierType = _
pub const MOD4_MASK: ModifierType = _
pub const MOD5_MASK: ModifierType = _
pub const BUTTON1_MASK: ModifierType = _
pub const BUTTON2_MASK: ModifierType = _
pub const BUTTON3_MASK: ModifierType = _
pub const BUTTON4_MASK: ModifierType = _
pub const BUTTON5_MASK: ModifierType = _
pub const MODIFIER_RESERVED_13_MASK: ModifierType = _
pub const MODIFIER_RESERVED_14_MASK: ModifierType = _
pub const MODIFIER_RESERVED_15_MASK: ModifierType = _
pub const MODIFIER_RESERVED_16_MASK: ModifierType = _
pub const MODIFIER_RESERVED_17_MASK: ModifierType = _
pub const MODIFIER_RESERVED_18_MASK: ModifierType = _
pub const MODIFIER_RESERVED_19_MASK: ModifierType = _
pub const MODIFIER_RESERVED_20_MASK: ModifierType = _
pub const MODIFIER_RESERVED_21_MASK: ModifierType = _
pub const MODIFIER_RESERVED_22_MASK: ModifierType = _
pub const MODIFIER_RESERVED_23_MASK: ModifierType = _
pub const MODIFIER_RESERVED_24_MASK: ModifierType = _
pub const MODIFIER_RESERVED_25_MASK: ModifierType = _
pub const SUPER_MASK: ModifierType = _
pub const HYPER_MASK: ModifierType = _
pub const META_MASK: ModifierType = _
pub const MODIFIER_RESERVED_29_MASK: ModifierType = _
pub const RELEASE_MASK: ModifierType = _
pub const MODIFIER_MASK: ModifierType = _
sourcepub const fn empty() -> ModifierType
pub const fn empty() -> ModifierType
Returns an empty set of flags
sourcepub const fn all() -> ModifierType
pub const fn all() -> ModifierType
Returns the set containing all flags.
sourcepub fn from_bits(bits: u32) -> Option<ModifierType>
pub fn from_bits(bits: u32) -> Option<ModifierType>
Convert from underlying bit representation, unless that representation contains bits that do not correspond to a flag.
sourcepub const fn from_bits_truncate(bits: u32) -> ModifierType
pub const fn from_bits_truncate(bits: u32) -> ModifierType
Convert from underlying bit representation, dropping any bits that do not correspond to flags.
sourcepub const unsafe fn from_bits_unchecked(bits: u32) -> ModifierType
pub const unsafe fn from_bits_unchecked(bits: u32) -> ModifierType
Convert from underlying bit representation, preserving all bits (even those not corresponding to a defined flag).
sourcepub const fn intersects(&self, other: ModifierType) -> bool
pub const fn intersects(&self, other: ModifierType) -> bool
Returns true if there are flags common to both self and other.
sourcepub const fn contains(&self, other: ModifierType) -> bool
pub const fn contains(&self, other: ModifierType) -> bool
Returns true all of the flags in other are contained within self.
sourcepub fn insert(&mut self, other: ModifierType)
pub fn insert(&mut self, other: ModifierType)
Inserts the specified flags in-place.
sourcepub fn remove(&mut self, other: ModifierType)
pub fn remove(&mut self, other: ModifierType)
Removes the specified flags in-place.
sourcepub fn toggle(&mut self, other: ModifierType)
pub fn toggle(&mut self, other: ModifierType)
Toggles the specified flags in-place.
sourcepub fn set(&mut self, other: ModifierType, value: bool)
pub fn set(&mut self, other: ModifierType, value: bool)
Inserts or removes the specified flags depending on the passed value.
Trait Implementations
sourceimpl Binary for ModifierType
impl Binary for ModifierType
sourceimpl BitAnd<ModifierType> for ModifierType
impl BitAnd<ModifierType> for ModifierType
sourcefn bitand(self, other: ModifierType) -> ModifierType
fn bitand(self, other: ModifierType) -> ModifierType
Returns the intersection between the two sets of flags.
type Output = ModifierType
type Output = ModifierType
& operator.sourceimpl BitAndAssign<ModifierType> for ModifierType
impl BitAndAssign<ModifierType> for ModifierType
sourcefn bitand_assign(&mut self, other: ModifierType)
fn bitand_assign(&mut self, other: ModifierType)
Disables all flags disabled in the set.
sourceimpl BitOr<ModifierType> for ModifierType
impl BitOr<ModifierType> for ModifierType
sourcefn bitor(self, other: ModifierType) -> ModifierType
fn bitor(self, other: ModifierType) -> ModifierType
Returns the union of the two sets of flags.
type Output = ModifierType
type Output = ModifierType
| operator.sourceimpl BitOrAssign<ModifierType> for ModifierType
impl BitOrAssign<ModifierType> for ModifierType
sourcefn bitor_assign(&mut self, other: ModifierType)
fn bitor_assign(&mut self, other: ModifierType)
Adds the set of flags.
sourceimpl BitXor<ModifierType> for ModifierType
impl BitXor<ModifierType> for ModifierType
sourcefn bitxor(self, other: ModifierType) -> ModifierType
fn bitxor(self, other: ModifierType) -> ModifierType
Returns the left flags, but with all the right flags toggled.
type Output = ModifierType
type Output = ModifierType
^ operator.sourceimpl BitXorAssign<ModifierType> for ModifierType
impl BitXorAssign<ModifierType> for ModifierType
sourcefn bitxor_assign(&mut self, other: ModifierType)
fn bitxor_assign(&mut self, other: ModifierType)
Toggles the set of flags.
sourceimpl Clone for ModifierType
impl Clone for ModifierType
sourcefn clone(&self) -> ModifierType
fn clone(&self) -> ModifierType
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresourceimpl Debug for ModifierType
impl Debug for ModifierType
sourceimpl Extend<ModifierType> for ModifierType
impl Extend<ModifierType> for ModifierType
sourcefn extend<T: IntoIterator<Item = ModifierType>>(&mut self, iterator: T)
fn extend<T: IntoIterator<Item = ModifierType>>(&mut self, iterator: T)
sourcefn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one)sourcefn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one)sourceimpl FromIterator<ModifierType> for ModifierType
impl FromIterator<ModifierType> for ModifierType
sourcefn from_iter<T: IntoIterator<Item = ModifierType>>(iterator: T) -> ModifierType
fn from_iter<T: IntoIterator<Item = ModifierType>>(iterator: T) -> ModifierType
sourceimpl<'a> FromValue<'a> for ModifierType
impl<'a> FromValue<'a> for ModifierType
unsafe fn from_value(value: &Value) -> Self
sourceimpl<'a> FromValueOptional<'a> for ModifierType
impl<'a> FromValueOptional<'a> for ModifierType
unsafe fn from_value_optional(value: &Value) -> Option<Self>
sourceimpl Hash for ModifierType
impl Hash for ModifierType
sourceimpl LowerHex for ModifierType
impl LowerHex for ModifierType
sourceimpl Not for ModifierType
impl Not for ModifierType
sourcefn not(self) -> ModifierType
fn not(self) -> ModifierType
Returns the complement of this set of flags.
type Output = ModifierType
type Output = ModifierType
! operator.sourceimpl Octal for ModifierType
impl Octal for ModifierType
sourceimpl Ord for ModifierType
impl Ord for ModifierType
sourcefn cmp(&self, other: &ModifierType) -> Ordering
fn cmp(&self, other: &ModifierType) -> Ordering
1.21.0 · sourcefn max(self, other: Self) -> Self
fn max(self, other: Self) -> Self
1.21.0 · sourcefn min(self, other: Self) -> Self
fn min(self, other: Self) -> Self
1.50.0 · sourcefn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
sourceimpl PartialEq<ModifierType> for ModifierType
impl PartialEq<ModifierType> for ModifierType
sourcefn eq(&self, other: &ModifierType) -> bool
fn eq(&self, other: &ModifierType) -> bool
sourceimpl PartialOrd<ModifierType> for ModifierType
impl PartialOrd<ModifierType> for ModifierType
sourcefn partial_cmp(&self, other: &ModifierType) -> Option<Ordering>
fn partial_cmp(&self, other: &ModifierType) -> Option<Ordering>
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self and other) and is used by the <=
operator. Read moresourceimpl StaticType for ModifierType
impl StaticType for ModifierType
sourcefn static_type() -> Type
fn static_type() -> Type
Self.sourceimpl Sub<ModifierType> for ModifierType
impl Sub<ModifierType> for ModifierType
sourcefn sub(self, other: ModifierType) -> ModifierType
fn sub(self, other: ModifierType) -> ModifierType
Returns the set difference of the two sets of flags.
type Output = ModifierType
type Output = ModifierType
- operator.sourceimpl SubAssign<ModifierType> for ModifierType
impl SubAssign<ModifierType> for ModifierType
sourcefn sub_assign(&mut self, other: ModifierType)
fn sub_assign(&mut self, other: ModifierType)
Disables all flags enabled in the set.
sourceimpl UpperHex for ModifierType
impl UpperHex for ModifierType
impl Copy for ModifierType
impl Eq for ModifierType
impl StructuralEq for ModifierType
impl StructuralPartialEq for ModifierType
Auto Trait Implementations
impl RefUnwindSafe for ModifierType
impl Send for ModifierType
impl Sync for ModifierType
impl Unpin for ModifierType
impl UnwindSafe for ModifierType
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
sourceimpl<T> ToSendValue for Twhere
T: SetValue + Send + ToValue + ?Sized,
impl<T> ToSendValue for Twhere
T: SetValue + Send + ToValue + ?Sized,
sourcefn to_send_value(&self) -> SendValue
fn to_send_value(&self) -> SendValue
SendValue clone of self.