Struct etagere::AllocatorOptions
source · pub struct AllocatorOptions {
pub alignment: Size,
pub vertical_shelves: bool,
pub num_columns: i32,
}
Expand description
Options to tweak the behavior of the atlas allocator.
Fields§
§alignment: Size
Align item sizes to a multiple of this alignment.
Default value: [1, 1] (no alignment).
vertical_shelves: bool
Use vertical instead of horizontal shelves.
Default value: false.
num_columns: i32
If possible split the allocator’s surface into multiple columns.
Having multiple columns allows having more (smaller shelves).
Default value: 1.
Trait Implementations§
source§impl Clone for AllocatorOptions
impl Clone for AllocatorOptions
source§fn clone(&self) -> AllocatorOptions
fn clone(&self) -> AllocatorOptions
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 AllocatorOptions
impl Debug for AllocatorOptions
source§impl Default for AllocatorOptions
impl Default for AllocatorOptions
source§impl<'de> Deserialize<'de> for AllocatorOptions
impl<'de> Deserialize<'de> for AllocatorOptions
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 Hash for AllocatorOptions
impl Hash for AllocatorOptions
source§impl PartialEq for AllocatorOptions
impl PartialEq for AllocatorOptions
source§fn eq(&self, other: &AllocatorOptions) -> bool
fn eq(&self, other: &AllocatorOptions) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for AllocatorOptions
impl Serialize for AllocatorOptions
impl Copy for AllocatorOptions
impl Eq for AllocatorOptions
impl StructuralPartialEq for AllocatorOptions
Auto Trait Implementations§
impl Freeze for AllocatorOptions
impl RefUnwindSafe for AllocatorOptions
impl Send for AllocatorOptions
impl Sync for AllocatorOptions
impl Unpin for AllocatorOptions
impl UnwindSafe for AllocatorOptions
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