pub struct CommonItemProperties {
pub clip_rect: LayoutRect,
pub clip_id: ClipId,
pub spatial_id: SpatialId,
pub flags: PrimitiveFlags,
}
Expand description
A grouping of fields a lot of display items need, just to avoid repeating these over and over in this file.
Fields§
§clip_rect: LayoutRect
Bounds of the display item to clip to. Many items are logically infinite, and rely on this clip_rect to define their bounds (solid colors, background-images, gradients, etc).
clip_id: ClipId
Additional clips
spatial_id: SpatialId
The coordinate-space the item is in (yes, it can be really granular)
flags: PrimitiveFlags
Various flags describing properties of this primitive.
Implementations§
Source§impl CommonItemProperties
impl CommonItemProperties
Sourcepub fn new(clip_rect: LayoutRect, space_and_clip: SpaceAndClipInfo) -> Self
pub fn new(clip_rect: LayoutRect, space_and_clip: SpaceAndClipInfo) -> Self
Convenience for tests.
Trait Implementations§
Source§impl Clone for CommonItemProperties
impl Clone for CommonItemProperties
Source§fn clone(&self) -> CommonItemProperties
fn clone(&self) -> CommonItemProperties
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 Debug for CommonItemProperties
impl Debug for CommonItemProperties
Source§impl Default for CommonItemProperties
impl Default for CommonItemProperties
Source§fn default() -> CommonItemProperties
fn default() -> CommonItemProperties
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for CommonItemProperties
impl<'de> Deserialize<'de> for CommonItemProperties
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
Source§impl PartialEq for CommonItemProperties
impl PartialEq for CommonItemProperties
Source§impl Peek for CommonItemProperties
impl Peek for CommonItemProperties
Source§impl Poke for CommonItemProperties
impl Poke for CommonItemProperties
Source§impl Serialize for CommonItemProperties
impl Serialize for CommonItemProperties
impl Copy for CommonItemProperties
impl StructuralPartialEq for CommonItemProperties
Auto Trait Implementations§
impl Freeze for CommonItemProperties
impl RefUnwindSafe for CommonItemProperties
impl Send for CommonItemProperties
impl Sync for CommonItemProperties
impl Unpin for CommonItemProperties
impl UnwindSafe for CommonItemProperties
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