pub struct GridTemplate {
pub rows: Vec<TrackSizing>,
pub cols: Vec<TrackSizing>,
pub areas: Option<Vec<Vec<Option<String>>>>,
pub row_gap: f32,
pub col_gap: f32,
}Expand description
A CSS grid template: track definitions, named areas, and gutters.
Fields§
§rows: Vec<TrackSizing>Sizing functions for explicit row tracks (top to bottom).
cols: Vec<TrackSizing>Sizing functions for explicit column tracks (left to right).
areas: Option<Vec<Vec<Option<String>>>>Optional named area grid: areas[row_idx][col_idx] is the area name
(or None for an unnamed cell). Row and column indices are zero-based.
row_gap: f32Gap (gutter) between adjacent row tracks in logical pixels.
col_gap: f32Gap (gutter) between adjacent column tracks in logical pixels.
Trait Implementations§
Source§impl Clone for GridTemplate
impl Clone for GridTemplate
Source§fn clone(&self) -> GridTemplate
fn clone(&self) -> GridTemplate
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 GridTemplate
impl Debug for GridTemplate
Source§impl Default for GridTemplate
impl Default for GridTemplate
Source§fn default() -> GridTemplate
fn default() -> GridTemplate
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for GridTemplate
impl RefUnwindSafe for GridTemplate
impl Send for GridTemplate
impl Sync for GridTemplate
impl Unpin for GridTemplate
impl UnsafeUnpin for GridTemplate
impl UnwindSafe for GridTemplate
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