class layout.Grid(Widget)
A Grid
is a container widget that lays out a collection of widgets as a
regular grid of rows and columns. In an OpenGL window, it may contain
3D subwidgets.
The layout is only performed when the widget is initially created; it
is not updated if you add or remove widgets later or change their sizes.
Note: Don't confuse this with the GridView class, which performs a different function.
Constructor
- Grid(rows, row_spacing = 10, column_spacing = 10)
- The
rows should be a sequence of sequences of widgets, with each item in
the outer sequence corresponding to one row of the grid. The
row_spacing and column_spacing
specify how much space to leave between
rows and columns. The height of each row and the width of each column
are determined by the sizes of the widgets that they are to contain.
---