This class holds the header window for UltimateListCtrl
.
__init__ |
Default class constructor. |
AdjustDC |
Shifts the wx.DC origin to match the position of the main window horizontal |
DoGetBestSize |
Gets the size which best suits the window: for a control, it would be the |
DrawCurrent |
Force the redrawing of the column window. |
DrawTextFormatted |
Draws the item text, correctly formatted. |
GetOwner |
Returns the header window owner, an instance of UltimateListCtrl . |
GetTextHeight |
Returns the column text height, in pixels. |
GetWindowHeight |
Returns the UltimateListHeaderWindow height, in pixels. |
HandleColumnCheck |
Handles the case in which a column contains a checkbox-like item. |
HitTestColumn |
HitTest method for column headers. |
IsColumnShown |
Returns True if the input column is shown, False if it is hidden. |
OnEnterWindow |
Handles the wx.EVT_ENTER_WINDOW event for UltimateListHeaderWindow . |
OnInternalIdle |
This method is normally only used internally, but sometimes an application |
OnLeaveWindow |
Handles the wx.EVT_LEAVE_WINDOW event for UltimateListHeaderWindow . |
OnMouse |
Handles the wx.EVT_MOUSE_EVENTS event for UltimateListHeaderWindow . |
OnPaint |
Handles the wx.EVT_PAINT event for UltimateListHeaderWindow . |
OnSetFocus |
Handles the wx.EVT_SET_FOCUS event for UltimateListHeaderWindow . |
SendListEvent |
Sends a UltimateListEvent for the parent window. |
SetCustomRenderer |
Associate a custom renderer with the header - all columns will use it |
UltimateListHeaderWindow
(wx.Control)¶This class holds the header window for UltimateListCtrl
.
__init__
(self, win, id, owner, pos=wx.DefaultPosition, size=wx.DefaultSize, style=0, validator=wx.DefaultValidator, name="UltimateListCtrlcolumntitles", isFooter=False)¶Default class constructor.
Parameters: |
|
---|
AdjustDC
(self, dc)¶Shifts the wx.DC
origin to match the position of the main window horizontal
scrollbar: this allows us to always use logical coordinates.
Parameters: | dc – an instance of wx.DC . |
---|
DoGetBestSize
(self)¶Gets the size which best suits the window: for a control, it would be the minimal size which doesn’t truncate the control, for a panel - the same size as it would have after a call to Fit().
DrawCurrent
(self)¶Force the redrawing of the column window.
DrawTextFormatted
(self, dc, text, rect)¶Draws the item text, correctly formatted.
Parameters: |
|
---|
GetOwner
(self)¶Returns the header window owner, an instance of UltimateListCtrl
.
GetTextHeight
(self)¶Returns the column text height, in pixels.
GetWindowHeight
(self)¶Returns the UltimateListHeaderWindow
height, in pixels.
HandleColumnCheck
(self, column, pos)¶Handles the case in which a column contains a checkbox-like item.
Parameters: |
|
---|
HitTestColumn
(self, x, y)¶HitTest method for column headers.
Parameters: |
|
---|---|
Returns: | The column index if any column client rectangle contains the mouse
position, |
IsColumnShown
(self, column)¶Returns True
if the input column is shown, False
if it is hidden.
Parameters: | column – an integer specifying the column index. |
---|
OnEnterWindow
(self, event)¶Handles the wx.EVT_ENTER_WINDOW
event for UltimateListHeaderWindow
.
Parameters: | event – a MouseEvent event to be processed. |
---|
OnInternalIdle
(self)¶This method is normally only used internally, but sometimes an application may need it to implement functionality that should not be disabled by an application defining an OnIdle handler in a derived class.
This method may be used to do delayed painting, for example, and most
implementations call wx.Window.UpdateWindowUI
in order to send update events
to the window in idle time.
OnLeaveWindow
(self, event)¶Handles the wx.EVT_LEAVE_WINDOW
event for UltimateListHeaderWindow
.
Parameters: | event – a MouseEvent event to be processed. |
---|
OnMouse
(self, event)¶Handles the wx.EVT_MOUSE_EVENTS
event for UltimateListHeaderWindow
.
Parameters: | event – a MouseEvent event to be processed. |
---|
OnPaint
(self, event)¶Handles the wx.EVT_PAINT
event for UltimateListHeaderWindow
.
Parameters: | event – a PaintEvent event to be processed. |
---|
OnSetFocus
(self, event)¶Handles the wx.EVT_SET_FOCUS
event for UltimateListHeaderWindow
.
Parameters: | event – a FocusEvent event to be processed. |
---|
SendListEvent
(self, eventType, pos)¶Sends a UltimateListEvent
for the parent window.
Parameters: |
|
---|
SetCustomRenderer
(self, renderer=None)¶Associate a custom renderer with the header - all columns will use it
Parameters: | renderer – a class able to correctly render header buttons |
---|
Note
the renderer class must implement the methods DrawHeaderButton and GetForegroundColor.