pub trait Layout2d {
type Px: Default;
// Required methods
fn layout_dft(&self, default: Self::Px) -> Self::Px;
fn affect_mask(&self) -> LayoutMask;
// Provided method
fn layout(&self) -> Self::Px { ... }
}Expand description
Represents a two-dimensional value that can be converted to a pixel value in a LAYOUT context.
Required Associated Types§
Required Methods§
Sourcefn layout_dft(&self, default: Self::Px) -> Self::Px
fn layout_dft(&self, default: Self::Px) -> Self::Px
Compute the pixel value in the current LAYOUT context with default.
Sourcefn affect_mask(&self) -> LayoutMask
fn affect_mask(&self) -> LayoutMask
Compute a LayoutMask that flags all contextual values that affect the result of layout.
Provided Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".