WidgetGridBox Class
This class creates a grid box.
WidgetGridBox Class
This class inherits from WidgetVBoxMembers
WidgetGridBox (Gui gui, int columns = 2, int space_x = 0, int space_y = 0)
Constructor. Creates a grid box with given parameters.Arguments
- Gui gui - GUI, to which the new box will belong.
- int columns - Number of columns in the grid. This is an optional parameter.
- int space_x - Horizontal space between the widgets in the box and between them and the box border. This is an optional parameter.
- int space_y - Vertical space between the widgets in the box and between them and the box border. This is an optional parameter.
int getColumnRatio (int num)
Returns the current width-to-height ratio of the specified column.Arguments
- int num - Column number in range from 0 to the total number of columns.
Return value
Width-to-height ratio.int getNumColumns ()
Returns the number of columns in the grid.Return value
Number of columns.void setColumnRatio (int num, int ratio)
Sets the width-to-height ratio of the specified column.Arguments
- int num - Column number in range from 0 to the total number of columns.
- int ratio - Width-to-height ratio.
void setNumColumns (int num)
Sets a number of columns in the grid.Arguments
- int num - Number of columns.
Last update: 2017-07-03
Help improve this article
Was this article helpful?
(or select a word/phrase and press Ctrl+Enter)