wxGridBagSizer

wxGridBagSizer

wxGridBagSizer
Functions for wxGridBagSizer class

A wxSizer that can lay out items in a virtual grid like a wxFlexGridSizer but in this case explicit positioning of the items is allowed using wxGBPosition (not implemented in wx), and items can optionally span more than one row and/or column using wxGBSpan (not implemented in wx).

This class is derived (and can use functions) from: wxFlexGridSizer wxGridSizer wxSizer

wxWidgets docs: wxGridBagSizer

Types

Option = {vgap, integer()} | {hgap, integer()}

Constructor, with optional parameters to specify the gap between the rows and columns.

Types

Pos = {R :: integer(), C :: integer()}
Option =
    {span, {RS :: integer(), CS :: integer()}} |
    {flag, integer()} |
    {border, integer()} |
    {userData, wx:wx_object()}

Adds the given item to the given position.

Return: A valid pointer if the item was successfully placed at the given position, or NULL if something was already there.

Types

Width = Height = integer()
Pos = {R :: integer(), C :: integer()}
Option =
    {span, {RS :: integer(), CS :: integer()}} |
    {flag, integer()} |
    {border, integer()} |
    {userData, wx:wx_object()}

Adds a spacer to the given position.

width and height specify the dimension of the spacer to be added.

Return: A valid pointer if the spacer was successfully placed at the given position, or NULL if something was already there.

Look at all items and see if any intersect (or would overlap) the given item.

Returns true if so, false if there would be no overlap. If an excludeItem is given then it will not be checked for intersection, for example it may be the item we are checking the position of.

Types

Pt = {X :: integer(), Y :: integer()}

Return the sizer item located at the point given in pt, or NULL if there is no item at that point.

The (x,y) coordinates in pt correspond to the client coordinates of the window using the sizer for layout. (non-recursive)

Types

Row = Col = integer()

Get the size of the specified cell, including hgap and vgap.

Only valid after window layout has been performed.