pub struct StyleHint { /* private fields */ }
Implementations
sourceimpl StyleHint
impl StyleHint
pub const ShEtchDisabledText: Self = _
pub const ShDitherDisabledText: Self = _
pub const ShScrollBarMiddleClickAbsolutePosition: Self = _
pub const ShScrollBarScrollWhenPointerLeavesControl: Self = _
pub const ShTabBarSelectMouseType: Self = _
pub const ShTabBarAlignment: Self = _
pub const ShHeaderArrowAlignment: Self = _
pub const ShSliderSnapToValue: Self = _
pub const ShSliderSloppyKeyEvents: Self = _
pub const ShProgressDialogCenterCancelButton: Self = _
pub const ShProgressDialogTextLabelAlignment: Self = _
pub const ShPrintDialogRightAlignButtons: Self = _
pub const ShMainWindowSpaceBelowMenuBar: Self = _
pub const ShFontDialogSelectAssociatedText: Self = _
pub const ShMenuAllowActiveAndDisabled: Self = _
pub const ShMenuSpaceActivatesItem: Self = _
pub const ShMenuSubMenuPopupDelay: Self = _
pub const ShScrollViewFrameOnlyAroundContents: Self = _
pub const ShComboBoxListMouseTracking: Self = _
pub const ShMenuMouseTracking: Self = _
pub const ShMenuBarMouseTracking: Self = _
pub const ShItemViewChangeHighlightOnFocus: Self = _
pub const ShWorkspaceFillSpaceOnMaximize: Self = _
pub const ShComboBoxPopup: Self = _
pub const ShTitleBarNoBorder: Self = _
pub const ShSliderStopMouseOverSlider: Self = _
pub const ShScrollBarStopMouseOverSlider: Self = _
pub const ShBlinkCursorWhenTextSelected: Self = _
pub const ShRichTextFullWidthSelection: Self = _
pub const ShMenuScrollable: Self = _
pub const ShGroupBoxTextLabelVerticalAlignment: Self = _
pub const ShGroupBoxTextLabelColor: Self = _
pub const ShMenuSloppySubMenus: Self = _
pub const ShTableGridLineColor: Self = _
pub const ShLineEditPasswordCharacter: Self = _
pub const ShDialogButtonsDefaultButton: Self = _
pub const ShToolBoxSelectedPageTitleBold: Self = _
pub const ShTabBarPreferNoArrows: Self = _
pub const ShScrollBarLeftClickAbsolutePosition: Self = _
pub const ShListViewExpandSelectMouseType: Self = _
pub const ShUnderlineShortcut: Self = _
pub const ShSpinBoxAnimateButton: Self = _
pub const ShSpinBoxKeyPressAutoRepeatRate: Self = _
pub const ShSpinBoxClickAutoRepeatRate: Self = _
pub const ShMenuFillScreenWithScroll: Self = _
pub const ShToolTipLabelOpacity: Self = _
pub const ShDrawMenuBarSeparator: Self = _
pub const ShTitleBarModifyNotification: Self = _
pub const ShButtonFocusPolicy: Self = _
pub const ShMessageBoxUseBorderForButtonSpacing: Self = _
pub const ShTitleBarAutoRaise: Self = _
pub const ShToolButtonPopupDelay: Self = _
pub const ShFocusFrameMask: Self = _
pub const ShRubberBandMask: Self = _
pub const ShWindowFrameMask: Self = _
pub const ShSpinControlsDisableOnBounds: Self = _
pub const ShDialBackgroundRole: Self = _
pub const ShComboBoxLayoutDirection: Self = _
pub const ShItemViewEllipsisLocation: Self = _
pub const ShItemViewShowDecorationSelected: Self = _
pub const ShItemViewActivateItemOnSingleClick: Self = _
pub const ShScrollBarContextMenu: Self = _
pub const ShScrollBarRollBetweenButtons: Self = _
pub const ShSliderAbsoluteSetButtons: Self = _
pub const ShSliderPageSetButtons: Self = _
pub const ShMenuKeyboardSearch: Self = _
pub const ShTabBarElideMode: Self = _
pub const ShDialogButtonLayout: Self = _
pub const ShComboBoxPopupFrameStyle: Self = _
pub const ShMessageBoxTextInteractionFlags: Self = _
pub const ShDialogButtonBoxButtonsHaveIcons: Self = _
pub const ShSpellCheckUnderlineStyle: Self = _
pub const ShMessageBoxCenterButtons: Self = _
pub const ShMenuSelectionWrap: Self = _
pub const ShItemViewMovementWithoutUpdatingSelection: Self = _
pub const ShToolTipMask: Self = _
pub const ShFocusFrameAboveWidget: Self = _
pub const ShTextControlFocusIndicatorTextCharFormat: Self = _
pub const ShWizardStyle: Self = _
pub const ShMenuMask: Self = _
pub const ShMenuFlashTriggeredItem: Self = _
pub const ShMenuFadeOutOnHide: Self = _
pub const ShSpinBoxClickAutoRepeatThreshold: Self = _
pub const ShItemViewPaintAlternatingRowColorsForEmptyArea: Self = _
pub const ShFormLayoutWrapPolicy: Self = _
pub const ShTabWidgetDefaultTabPosition: Self = _
pub const ShToolBarMovable: Self = _
pub const ShFormLayoutFieldGrowthPolicy: Self = _
pub const ShFormLayoutFormAlignment: Self = _
pub const ShFormLayoutLabelAlignment: Self = _
pub const ShItemViewDrawDelegateFrame: Self = _
pub const ShTabBarCloseButtonPosition: Self = _
pub const ShDockWidgetButtonsHaveFrame: Self = _
pub const ShToolButtonStyle: Self = _
pub const ShRequestSoftwareInputPanel: Self = _
pub const ShScrollBarTransient: Self = _
pub const ShMenuSupportsSections: Self = _
pub const ShToolTipWakeUpDelay: Self = _
pub const ShToolTipFallAsleepDelay: Self = _
pub const ShWidgetAnimate: Self = _
pub const ShSplitterOpaqueResize: Self = _
pub const ShComboBoxUseNativePopup: Self = _
pub const ShLineEditPasswordMaskDelay: Self = _
pub const ShTabBarChangeCurrentDelay: Self = _
pub const ShMenuSubMenuUniDirection: Self = _
pub const ShMenuSubMenuUniDirectionFailCount: Self = _
pub const ShMenuSubMenuSloppySelectOtherActions: Self = _
pub const ShMenuSubMenuSloppyCloseTimeout: Self = _
pub const ShMenuSubMenuResetWhenReenteringParent: Self = _
pub const ShMenuSubMenuDontStartSloppyOnLeave: Self = _
pub const ShItemViewScrollMode: Self = _
pub const ShTitleBarShowToolTipsOnButtons: Self = _
pub const ShWidgetAnimationDuration: Self = _
pub const ShComboBoxAllowWheelScrolling: Self = _
pub const ShSpinBoxButtonsInsideFrame: Self = _
pub const ShCustomBase: Self = _
sourcepub const fn from_bits(bits: u32) -> Option<Self>
pub const fn from_bits(bits: u32) -> Option<Self>
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) -> Self
pub const fn from_bits_truncate(bits: u32) -> Self
Convert from underlying bit representation, dropping any bits that do not correspond to flags.
sourcepub const unsafe fn from_bits_unchecked(bits: u32) -> Self
pub const unsafe fn from_bits_unchecked(bits: u32) -> Self
Convert from underlying bit representation, preserving all bits (even those not corresponding to a defined flag).
Safety
The caller of the bitflags!
macro can chose to allow or
disallow extra bits for their bitflags type.
The caller of from_bits_unchecked()
has to ensure that
all bits correspond to a defined flag or that extra bits
are valid for this bitflags type.
sourcepub const fn intersects(&self, other: Self) -> bool
pub const fn intersects(&self, other: Self) -> bool
Returns true
if there are flags common to both self
and other
.
sourcepub const fn contains(&self, other: Self) -> bool
pub const fn contains(&self, other: Self) -> bool
Returns true
if all of the flags in other
are contained within self
.
sourcepub fn set(&mut self, other: Self, value: bool)
pub fn set(&mut self, other: Self, value: bool)
Inserts or removes the specified flags depending on the passed value.
sourcepub const fn intersection(self, other: Self) -> Self
pub const fn intersection(self, other: Self) -> Self
Returns the intersection between the flags in self
and
other
.
Specifically, the returned set contains only the flags which are
present in both self
and other
.
This is equivalent to using the &
operator (e.g.
ops::BitAnd
), as in flags & other
.
sourcepub const fn union(self, other: Self) -> Self
pub const fn union(self, other: Self) -> Self
Returns the union of between the flags in self
and other
.
Specifically, the returned set contains all flags which are
present in either self
or other
, including any which are
present in both (see Self::symmetric_difference
if that
is undesirable).
This is equivalent to using the |
operator (e.g.
ops::BitOr
), as in flags | other
.
sourcepub const fn difference(self, other: Self) -> Self
pub const fn difference(self, other: Self) -> Self
Returns the difference between the flags in self
and other
.
Specifically, the returned set contains all flags present in
self
, except for the ones present in other
.
It is also conceptually equivalent to the “bit-clear” operation:
flags & !other
(and this syntax is also supported).
This is equivalent to using the -
operator (e.g.
ops::Sub
), as in flags - other
.
sourcepub const fn symmetric_difference(self, other: Self) -> Self
pub const fn symmetric_difference(self, other: Self) -> Self
Returns the symmetric difference between the flags
in self
and other
.
Specifically, the returned set contains the flags present which
are present in self
or other
, but that are not present in
both. Equivalently, it contains the flags present in exactly
one of the sets self
and other
.
This is equivalent to using the ^
operator (e.g.
ops::BitXor
), as in flags ^ other
.
sourcepub const fn complement(self) -> Self
pub const fn complement(self) -> Self
Returns the complement of this set of flags.
Specifically, the returned set contains all the flags which are
not set in self
, but which are allowed for this type.
Alternatively, it can be thought of as the set difference
between Self::all()
and self
(e.g. Self::all() - self
)
This is equivalent to using the !
operator (e.g.
ops::Not
), as in !flags
.
Trait Implementations
sourceimpl BitAndAssign<StyleHint> for StyleHint
impl BitAndAssign<StyleHint> for StyleHint
sourcefn bitand_assign(&mut self, other: Self)
fn bitand_assign(&mut self, other: Self)
Disables all flags disabled in the set.
sourceimpl BitOrAssign<StyleHint> for StyleHint
impl BitOrAssign<StyleHint> for StyleHint
sourcefn bitor_assign(&mut self, other: Self)
fn bitor_assign(&mut self, other: Self)
Adds the set of flags.
sourceimpl BitXorAssign<StyleHint> for StyleHint
impl BitXorAssign<StyleHint> for StyleHint
sourcefn bitxor_assign(&mut self, other: Self)
fn bitxor_assign(&mut self, other: Self)
Toggles the set of flags.
sourceimpl Extend<StyleHint> for StyleHint
impl Extend<StyleHint> for StyleHint
sourcefn extend<T: IntoIterator<Item = Self>>(&mut self, iterator: T)
fn extend<T: IntoIterator<Item = Self>>(&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<StyleHint> for StyleHint
impl FromIterator<StyleHint> for StyleHint
sourcefn from_iter<T: IntoIterator<Item = Self>>(iterator: T) -> Self
fn from_iter<T: IntoIterator<Item = Self>>(iterator: T) -> Self
sourceimpl Ord for StyleHint
impl Ord for StyleHint
1.21.0 · sourcefn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
1.21.0 · sourcefn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
1.50.0 · sourcefn clamp(self, min: Self, max: Self) -> Selfwhere
Self: Sized + PartialOrd<Self>,
fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: Sized + PartialOrd<Self>,
sourceimpl PartialOrd<StyleHint> for StyleHint
impl PartialOrd<StyleHint> for StyleHint
sourcefn partial_cmp(&self, other: &StyleHint) -> Option<Ordering>
fn partial_cmp(&self, other: &StyleHint) -> 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 SubAssign<StyleHint> for StyleHint
impl SubAssign<StyleHint> for StyleHint
sourcefn sub_assign(&mut self, other: Self)
fn sub_assign(&mut self, other: Self)
Disables all flags enabled in the set.