wx.GBPosition¶
This class represents the position of an item in a virtual grid of rows and columns managed by a wx.GridBagSizer.
Class Hierarchy¶
Methods Summary¶
Default constructor, setting the row and column to (0,0). |
|
Return the row and col properties as a tuple. |
|
Get the current column value. |
|
Returns an immutable representation of the |
|
Get the current row value. |
|
Set both the row and column properties. |
|
Set a new column value. |
|
Set a new row value. |
|
Compare inequality of two GBPositions. |
|
Compare equality of two GBPositions. |
Properties Summary¶
Class API¶
- class wx.GBPosition(object)¶
Possible constructors:
GBPosition() -> None GBPosition(row, col) -> None
This class represents the position of an item in a virtual grid of rows and columns managed by a GridBagSizer.
Methods¶
- __init__(self, *args, **kw)¶
-
__init__ (self)
Default constructor, setting the row and column to (0,0).
- Return type:
None
__init__ (self, row, col)
Construct a new wx.GBPosition, setting the row and column.
- Parameters:
row (int)
col (int)
- Return type:
None
- Get(self)¶
Return the row and col properties as a tuple.
- Return type:
Any
- GetCol(self)¶
Get the current column value.
- Return type:
int
- GetIM(self)¶
Returns an immutable representation of the
wx.GBPosition
object, based onnamedtuple
.This new object is hashable and can be used as a dictionary key, be added to sets, etc. It can be converted back into a real
wx.GBPosition
with a simple statement like this:obj = wx.GBPosition(imObj)
.
- GetRow(self)¶
Get the current row value.
- Return type:
int
- Set(self, row=0, col=0)¶
Set both the row and column properties.
- Return type:
None
- SetCol(self, col)¶
Set a new column value.
- Parameters:
col (int)
- Return type:
None
- SetRow(self, row)¶
Set a new row value.
- Parameters:
row (int)
- Return type:
None
- __bool__(self)¶
- __getitem__(self, idx)¶
- __len__(self)¶
- __nonzero__(self)¶
- __reduce__(self)¶
- __repr__(self)¶
- __setitem__(self, idx, val)¶
- __str__(self)¶
- __ne__(self, p)¶
Compare inequality of two GBPositions.
- Parameters:
p (wx.GBPosition)
- Return type:
bool
- __eq__(self, p)¶
Compare equality of two GBPositions.
- Parameters:
p (wx.GBPosition)
- Return type:
bool
Properties¶