wx.grid.GridRangeSelectEvent¶
Events of this class notify about a range of cells being selected.
When the user uses the mouse for selection, one or more SELECTING
events are generated first, with SELECTED
event generated at the end, when selection is final. This allows the application to handle either the SELECTING
events if it needs to update its state in real-time, as the selection changes, or just the final SELECTED
event, if updating its state on every selection change would be too time-consuming.
Note that if the user performs the selection from keyboard, SELECTING
events are not generated at all, so SELECTED
event still must be handled.
Finally, contrary to most of the other events with the name ending in “ing”, SELECTING
event can not be vetoed.
Events Emitted by this Class¶
Handlers bound for the following event types will receive a wx.grid.GridRangeSelectEvent parameter.
EVT_GRID_RANGE_SELECTING: The user is selecting a group of contiguous cells. Processes a
wxEVT_GRID_RANGE_SELECTING
event type. This event is available in wxWidgets 3.1.5 and later only.EVT_GRID_CMD_RANGE_SELECTING: The user is selecting a group of contiguous cells; variant taking a window identifier. Processes a
wxEVT_GRID_RANGE_SELECTING
event type. This event is available in wxWidgets 3.1.5 and later only.EVT_GRID_RANGE_SELECTED: The user selected a group of contiguous cells. Processes a
wxEVT_GRID_RANGE_SELECTED
event type. This event is available in wxWidgets 3.1.5 and later only and was calledwxEVT_GRID_RANGE_SELECT
in the previous versions.EVT_GRID_CMD_RANGE_SELECTED: The user selected a group of contiguous cells; variant taking a window identifier. Processes a
wxEVT_GRID_RANGE_SELECTED
event type. This event is available in wxWidgets 3.1.5 and later only and was calledwxEVT_GRID_CMD_RANGE_SELECT
in the previous versions.
Class Hierarchy¶
Methods Summary¶
Default constructor. |
|
Returns |
|
Returns |
|
Top left corner of the rectangular area that was (de)selected. |
|
Bottom row of the rectangular area that was (de)selected. |
|
Left column of the rectangular area that was (de)selected. |
|
Right column of the rectangular area that was (de)selected. |
|
Top left corner of the rectangular area that was (de)selected. |
|
Top row of the rectangular area that was (de)selected. |
|
Returns |
|
Returns |
|
Returns |
Properties Summary¶
See |
|
See |
|
See |
|
See |
|
See |
Class API¶
- class wx.grid.GridRangeSelectEvent(NotifyEvent)¶
Possible constructors:
GridRangeSelectEvent() -> None GridRangeSelectEvent(id, type, obj, topLeft, bottomRight, sel=True, kbd=KeyboardState()) -> None
Events of this class notify about a range of cells being selected.
Methods¶
- __init__(self, *args, **kw)¶
-
__init__ (self)
Default constructor.
- Return type:
None
__init__ (self, id, type, obj, topLeft, bottomRight, sel=True, kbd=KeyboardState())
Constructor for initializing all event attributes.
- Parameters:
id (int)
type (wx.EventType)
obj (wx.Object)
topLeft (wx.grid.GridCellCoords)
bottomRight (wx.grid.GridCellCoords)
sel (bool)
kbd (wx.KeyboardState)
- Return type:
None
- AltDown(self)¶
Returns
True
if the Alt key was down at the time of the event.- Return type:
bool
- ControlDown(self)¶
Returns
True
if the Control key was down at the time of the event.- Return type:
bool
- GetBottomRightCoords(self)¶
Top left corner of the rectangular area that was (de)selected.
- Return type:
- GetBottomRow(self)¶
Bottom row of the rectangular area that was (de)selected.
- Return type:
int
- GetLeftCol(self)¶
Left column of the rectangular area that was (de)selected.
- Return type:
int
- GetRightCol(self)¶
Right column of the rectangular area that was (de)selected.
- Return type:
int
- GetTopLeftCoords(self)¶
Top left corner of the rectangular area that was (de)selected.
- Return type:
- GetTopRow(self)¶
Top row of the rectangular area that was (de)selected.
- Return type:
int
- MetaDown(self)¶
Returns
True
if the Meta key was down at the time of the event.- Return type:
bool
- Selecting(self)¶
Returns
True
if the area was selected,False
otherwise.- Return type:
bool
- ShiftDown(self)¶
Returns
True
if the Shift key was down at the time of the event.- Return type:
bool
Properties¶
- BottomRightCoords¶
- BottomRow¶
See
GetBottomRow
- LeftCol¶
See
GetLeftCol
- RightCol¶
See
GetRightCol
- TopLeftCoords¶
See
GetTopLeftCoords