pub trait Alignable: Clone {
// Required methods
fn is_aligned(&self, other: &Self) -> bool;
fn align_with(&mut self, other: &mut Self);
}Expand description
A trait for aligning two items
Alignment is actually the meaning of preparation for interpolation.
For example, if we want to interpolate two VItems, we need to
align all their inner components like ComponentVec<VPoint> to the same length.
Required Methods§
Sourcefn is_aligned(&self, other: &Self) -> bool
fn is_aligned(&self, other: &Self) -> bool
Checking if two items are aligned
Sourcefn align_with(&mut self, other: &mut Self)
fn align_with(&mut self, other: &mut Self)
Aligning two items
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.