Columns (columns), Rows (rows) |
The track lists. A track is pixels (120 or 120px), a percent (25%), a fraction of the free space (1fr), auto (the size of the content) or minmax(min, max). repeat(3, 1fr) repeats tracks. repeat(auto-fill, ...) makes as many tracks as fit; repeat(auto-fit, ...) makes only as many as the items fill. An auto repeat needs a pixel or percent size. A track that the panel cannot read logs a warning. |
AutoRows (auto-rows), AutoColumns (auto-columns) |
The tracks of the rows and columns after the lists, in turn. auto by default. |
| Named lines |
[name] between the tracks of columns or rows names a line: [left] 100px [middle] 1fr [right]. One bracket can hold more names: [side-end main-start]. A name used twice means its first line. A line after an auto repeat counts the repeated tracks. Named lines inside repeat() are not read; they log a warning. |
Areas (areas) |
Named areas, like CSS grid-template-areas: one string of names per row, split by ; or in quotes ("a a" "b c" in C#). . is an empty cell. An area must be a rectangle; another shape logs a warning and is not used. An area main also names the lines main-start and main-end on both axes. Areas do not add tracks: the rows and columns come from the track lists and AutoRows and AutoColumns. |
RowGap (row-gap), ColumnGap (column-gap), Gap (gap) |
The space between the tracks in pixels. Gap sets both. |
AutoFlow (auto-flow) |
A GridFlow, with the values of CSS grid-auto-flow: Row fills each row first, Column fills each column first. RowDense and ColumnDense fill earlier holes with later items. |
JustifyItems (justify-items), AlignItems (align-items) |
The horizontal and vertical GridAlignment of the children in their areas: Start, Center, End or Stretch (the default). |
GridCell.Row (row), Column (column), RowSpan (row-span), ColumnSpan (column-span) |
A child with a set place. The row and column count from 1; 0 lets the panel pick. A cell with a row and a column is placed first. |
GridCell.Area (area) |
Like CSS grid-area: an area name, or row-start / column-start / row-end / column-end. Each line is a number from 1 or a name. A name finds name-start (or name-end for an end line) first, then name. A missing column start or end repeats a named start; a missing end after a number takes the span. An end before the start swaps them. It replaces Row and Column, and the span when it names both lines. A name that is not a line leaves that axis to the panel. |
GridCell.JustifySelf (justify-self), AlignSelf (align-self) |
The alignment of one cell. Auto takes the panel alignment. |
RowSizes, ColumnSizes, GetPlacement(child), Refresh() |
The track sizes and the area of a child from the last layout. The panel lays out again by itself when the children, their sizes or the settings change. |