pub struct LayerIndex(pub u32);Expand description
Represents a layer in a window.
See LAYERS for more information.
Tuple Fields§
§0: u32Implementations§
Source§impl LayerIndex
impl LayerIndex
Sourcepub const TOP_MOST: LayerIndex
pub const TOP_MOST: LayerIndex
The top-most layer.
Only widgets that are pretending to be a child window should use this layer, including menus, drop-downs, pop-ups and tooltips.
This is the u32::MAX value.
Sourcepub const ADORNER: LayerIndex
pub const ADORNER: LayerIndex
The layer for adorner display items.
Adorner widgets are related to another widget but not as a visual part of it, examples of adorners are resize handles in a widget visual editor, or an interactive help/guide feature.
This is the TOP_MOST - u16::MAX value.
Sourcepub const DEFAULT: LayerIndex
pub const DEFAULT: LayerIndex
The default layer, just above the normal window content.
This is the 0 value.
Sourcepub fn saturating_add(self, other: impl Into<LayerIndex>) -> LayerIndex
pub fn saturating_add(self, other: impl Into<LayerIndex>) -> LayerIndex
Compute self + other saturating at the TOP_MOST bound instead of overflowing.
Sourcepub fn saturating_sub(self, other: impl Into<LayerIndex>) -> LayerIndex
pub fn saturating_sub(self, other: impl Into<LayerIndex>) -> LayerIndex
Compute self - other saturating at the DEFAULT bound instead of overflowing.
Trait Implementations§
Source§impl<T> Add<T> for LayerIndexwhere
T: Into<LayerIndex>,
Calls LayerIndex::saturating_add.
impl<T> Add<T> for LayerIndexwhere
T: Into<LayerIndex>,
Calls LayerIndex::saturating_add.
Source§impl<T> AddAssign<T> for LayerIndexwhere
T: Into<LayerIndex>,
Calls LayerIndex::saturating_add.
impl<T> AddAssign<T> for LayerIndexwhere
T: Into<LayerIndex>,
Calls LayerIndex::saturating_add.
Source§fn add_assign(&mut self, rhs: T)
fn add_assign(&mut self, rhs: T)
+= operation. Read moreSource§impl Clone for LayerIndex
impl Clone for LayerIndex
Source§fn clone(&self) -> LayerIndex
fn clone(&self) -> LayerIndex
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for LayerIndex
impl Debug for LayerIndex
Source§impl Default for LayerIndex
impl Default for LayerIndex
Source§fn default() -> LayerIndex
fn default() -> LayerIndex
Source§impl<'de> Deserialize<'de> for LayerIndex
impl<'de> Deserialize<'de> for LayerIndex
Source§fn deserialize<D>(
deserializer: D,
) -> Result<LayerIndex, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<LayerIndex, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Source§impl Div<Factor> for LayerIndex
impl Div<Factor> for LayerIndex
Source§impl DivAssign<Factor> for LayerIndex
impl DivAssign<Factor> for LayerIndex
Source§fn div_assign(&mut self, rhs: Factor)
fn div_assign(&mut self, rhs: Factor)
/= operation. Read moreSource§impl From<u32> for LayerIndex
impl From<u32> for LayerIndex
Source§fn from(index: u32) -> LayerIndex
fn from(index: u32) -> LayerIndex
Source§impl FromStr for LayerIndex
impl FromStr for LayerIndex
Source§impl IntoVar<LayerIndex> for u32
impl IntoVar<LayerIndex> for u32
fn into_var(self) -> Var<LayerIndex>
Source§impl Mul<Factor> for LayerIndex
impl Mul<Factor> for LayerIndex
Source§impl MulAssign<Factor> for LayerIndex
impl MulAssign<Factor> for LayerIndex
Source§fn mul_assign(&mut self, rhs: Factor)
fn mul_assign(&mut self, rhs: Factor)
*= operation. Read moreSource§impl Ord for LayerIndex
impl Ord for LayerIndex
Source§fn cmp(&self, other: &LayerIndex) -> Ordering
fn cmp(&self, other: &LayerIndex) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for LayerIndex
impl PartialEq for LayerIndex
Source§impl PartialOrd for LayerIndex
impl PartialOrd for LayerIndex
Source§impl Serialize for LayerIndex
impl Serialize for LayerIndex
Source§fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
Source§impl<T> Sub<T> for LayerIndexwhere
T: Into<LayerIndex>,
Calls LayerIndex::saturating_sub.
impl<T> Sub<T> for LayerIndexwhere
T: Into<LayerIndex>,
Calls LayerIndex::saturating_sub.
Source§impl<T> SubAssign<T> for LayerIndexwhere
T: Into<LayerIndex>,
Calls LayerIndex::saturating_sub.
impl<T> SubAssign<T> for LayerIndexwhere
T: Into<LayerIndex>,
Calls LayerIndex::saturating_sub.
Source§fn sub_assign(&mut self, rhs: T)
fn sub_assign(&mut self, rhs: T)
-= operation. Read moreimpl Copy for LayerIndex
impl Eq for LayerIndex
impl IntoValue<LayerIndex> for u32
impl StructuralPartialEq for LayerIndex
Auto Trait Implementations§
impl Freeze for LayerIndex
impl RefUnwindSafe for LayerIndex
impl Send for LayerIndex
impl Sync for LayerIndex
impl Unpin for LayerIndex
impl UnwindSafe for LayerIndex
Blanket Implementations§
§impl<T> AnyEq for T
impl<T> AnyEq for T
Source§impl<T> AnyVarValue for T
impl<T> AnyVarValue for T
Source§fn clone_boxed(&self) -> BoxAnyVarValue
fn clone_boxed(&self) -> BoxAnyVarValue
Source§fn eq_any(&self, other: &(dyn AnyVarValue + 'static)) -> bool
fn eq_any(&self, other: &(dyn AnyVarValue + 'static)) -> bool
self and other are equal.Source§fn try_swap(&mut self, other: &mut (dyn AnyVarValue + 'static)) -> bool
fn try_swap(&mut self, other: &mut (dyn AnyVarValue + 'static)) -> bool
other if both are of the same type.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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Source§impl<T> FsChangeNote for T
impl<T> FsChangeNote for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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§impl<T> NoneValue for Twhere
T: Default,
impl<T> NoneValue for Twhere
T: Default,
type NoneType = T
§fn null_value() -> T
fn null_value() -> T
§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().