GridLayout

open class GridLayout(pointer: <Error class: unknown class><<Error class: unknown class>>) : LayoutManager

GtkGridLayout is a layout manager which arranges child widgets in rows and columns.

Children have an "attach point" defined by the horizontal and vertical index of the cell they occupy; children can span multiple rows or columns. The layout properties for setting the attach points and spans are set using the class@Gtk.GridLayoutChild associated to each child widget.

The behaviour of GtkGridLayout when several children occupy the same grid cell is undefined.

GtkGridLayout can be used like a GtkBoxLayout if all children are attached to the same row or column; however, if you only ever need a single row or column, you should consider using GtkBoxLayout.

Constructors

Link copied to clipboard
constructor()

Creates a new GtkGridLayout.

constructor(pointer: <Error class: unknown class><<Error class: unknown class>>)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
open var baselineRow: Int

The row to align to the baseline, when GtkWidget:valign is set to %GTK_ALIGN_BASELINE.

Link copied to clipboard

Whether all the columns in the grid have the same width.

Link copied to clipboard
open var columnSpacing: <Error class: unknown class>

The amount of space between to consecutive columns.

Link copied to clipboard
val gtkGridLayoutPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
val gtkLayoutManagerPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard

Whether all the rows in the grid have the same height.

Link copied to clipboard
open var rowSpacing: <Error class: unknown class>

The amount of space between to consecutive rows.

Functions

Link copied to clipboard
open fun allocate(widget: Widget, width: Int, height: Int, baseline: Int)

Assigns the given @width, @height, and @baseline to a @widget, and computes the position and sizes of the children of the @widget using the layout management policy of @manager.

Link copied to clipboard
open fun getBaselineRow(): Int

Retrieves the row set with gtk_grid_layout_set_baseline_row().

Link copied to clipboard

Checks whether all columns of @grid should have the same width.

Link copied to clipboard
open fun getColumnSpacing(): <Error class: unknown class>

Retrieves the spacing set with gtk_grid_layout_set_column_spacing().

Link copied to clipboard

Retrieves a GtkLayoutChild instance for the GtkLayoutManager, creating one if necessary.

Link copied to clipboard

Retrieves the request mode of @manager.

Link copied to clipboard

Returns the baseline position of @row.

Link copied to clipboard

Checks whether all rows of @grid should have the same height.

Link copied to clipboard
open fun getRowSpacing(): <Error class: unknown class>

Retrieves the spacing set with gtk_grid_layout_set_row_spacing().

Link copied to clipboard
open fun getWidget(): Widget?

Retrieves the GtkWidget using the given GtkLayoutManager.

Link copied to clipboard
open fun layoutChanged()

Queues a resize on the GtkWidget using @manager, if any.

Link copied to clipboard
open fun setBaselineRow(row: Int)

Sets which row defines the global baseline for the entire grid.

Link copied to clipboard
open fun setColumnHomogeneous(homogeneous: Boolean)

Sets whether all columns of @grid should have the same width.

Link copied to clipboard
open fun setColumnSpacing(spacing: <Error class: unknown class>)

Sets the amount of space to insert between consecutive columns.

Link copied to clipboard

Sets how the baseline should be positioned on @row of the grid, in case that row is assigned more space than is requested.

Link copied to clipboard
open fun setRowHomogeneous(homogeneous: Boolean)

Sets whether all rows of @grid should have the same height.

Link copied to clipboard
open fun setRowSpacing(spacing: <Error class: unknown class>)

Sets the amount of space to insert between consecutive rows.