class fwt::GridPane

sys::Obj
  fwt::Widget
    fwt::Pane
      fwt::GridPane

@Js
@Serializable { collection=true }

Source

GridPane is a container which lays out its children in a grid from left to right with a new row started based on numCols.

TODO: this API going to change, most likely there will be a switch to per col/per row configuration

expandCol

Int? expandCol := null

Source

If non-null, then this is a zero based column number to assign any extra width available beyond the preferred width. A negative number indexes from the last column. Default is null.

expandRow

Int? expandRow := null

Source

If non-null, then this is a zero based row number to assign any extra height available beyond the preferred height. A negative number indexes from the last row. Default is null.

halignCells

Halign halignCells := Halign.left

Source

Horizontal alignment of the individual cells. Defaults to left.

halignPane

Halign halignPane := Halign.left

Source

Horizontal alignment of the entire pane - this defines where the extra horizontal space beyond the preferred width goes. This field only makes sense when expandCol is null. Defaults to left.

hgap

Int hgap := 4

Source

Horizontal gap is number of pixels between left and right edges of adjacent cells. Default is 4.

numCols

Int numCols := 1

Source

Number of columns before wrapping to a new row. Default is 1.

onLayout

virtual override Void onLayout()

Source

prefSize

virtual override Size prefSize(Hints hints := Hints.defVal)

Source

uniformCols

Bool uniformCols := false

Source

If true, then all columns are given a uniform width which is computed from the widest column. If false then columns might be laid out with variable widths based on the width of the cells. Default is false.

uniformRows

Bool uniformRows := false

Source

If true, then all rows are given a uniform height which is computed from the highest row. If false then rows might be laid out with variable heights based on the highest of the cells. Default is false.

valignCells

Valign valignCells := Valign.center

Source

Vertical alignment of the individual cells. Defaults to center.

valignPane

Valign valignPane := Valign.top

Source

Vertial alignment of the entire pane - this defines where the extra vertial space beyond the preferred height goes. This field only makes sense when expandRow is null. Defaults to top.

vgap

Int vgap := 4

Source

Vertical gap is number of pixels between bottom and top edges of adjacent cells. Default is 4.