pub enum Align {
Default,
TL,
Center,
BR,
Stretch,
}
Expand description
Alignment of contents
Note that alignment information is often passed as a (horiz, vert)
pair.
Variants§
Default
Default alignment
This is context dependent. For example, for Left-To-Right text it means
TL
; for things which want to stretch it may mean Stretch
.
TL
Align to top or left
Center
Align to center
BR
Align to bottom or right
Stretch
Stretch to fill space
For text, this is known as “justified alignment”.
Trait Implementations§
source§impl Ord for Align
impl Ord for Align
source§impl PartialOrd<Align> for Align
impl PartialOrd<Align> for Align
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for Align
impl Eq for Align
impl StructuralEq for Align
impl StructuralPartialEq for Align
Auto Trait Implementations§
impl RefUnwindSafe for Align
impl Send for Align
impl Sync for Align
impl Unpin for Align
impl UnwindSafe for Align
Blanket Implementations§
source§impl<S, T> CastApprox<T> for Swhere
T: ConvApprox<S>,
impl<S, T> CastApprox<T> for Swhere
T: ConvApprox<S>,
source§fn try_cast_approx(self) -> Result<T, Error>
fn try_cast_approx(self) -> Result<T, Error>
source§fn cast_approx(self) -> T
fn cast_approx(self) -> T
source§impl<S, T> CastFloat<T> for Swhere
T: ConvFloat<S>,
impl<S, T> CastFloat<T> for Swhere
T: ConvFloat<S>,
source§fn cast_trunc(self) -> T
fn cast_trunc(self) -> T
Cast to integer, truncating Read more
source§fn cast_nearest(self) -> T
fn cast_nearest(self) -> T
Cast to the nearest integer Read more
source§fn cast_floor(self) -> T
fn cast_floor(self) -> T
Cast the floor to an integer Read more