wx.lib.agw.ribbon.art_aui.RibbonAUIArtProvider
, wx.lib.agw.ribbon.art_default.RibbonDefaultArtProvider
__init__ |
|
Clone |
Create a new art provider which is a clone of this one. |
CloneTo |
|
DrawButtonBarBackground |
Draw the background for a RibbonButtonBar control. |
DrawButtonBarButton |
Draw a single button for a RibbonButtonBar control. |
DrawButtonBarButtonForeground |
|
DrawDropdownArrow |
|
DrawGalleryBackground |
Draw the background and chrome for a RibbonGallery control. |
DrawGalleryBackgroundCommon |
|
DrawGalleryButton |
|
DrawGalleryItemBackground |
Draw the background of a single item in a RibbonGallery control. |
DrawMinimisedPanel |
Draw a minimised ribbon panel. |
DrawMinimisedPanelCommon |
|
DrawPageBackground |
Draw the background of a ribbon page. |
DrawPanelBackground |
Draw the background and chrome for a ribbon panel. |
DrawPanelBorder |
|
DrawPartialPageBackground |
|
DrawPartialPageBackground1 |
|
DrawPartialPageBackground2 |
|
DrawScrollButton |
Draw a ribbon-style scroll button. |
DrawTab |
Draw a single tab in the tab region of a ribbon bar. |
DrawTabCtrlBackground |
Draw the background of the tab region of a ribbon bar. |
DrawTabSeparator |
Draw a separator between two tabs in a ribbon bar. |
DrawTool |
Draw a single tool (for a RibbonToolBar control). |
DrawToolBarBackground |
Draw the background for a RibbonToolBar control. |
DrawToolGroupBackground |
Draw the background for a group of tools on a RibbonToolBar control. |
GetBarTabWidth |
Calculate the ideal and minimum width (in pixels) of a tab in a ribbon bar. |
GetButtonBarButtonSize |
Calculate the size of a button within a RibbonButtonBar . |
GetColour |
Get the value of a certain colour setting. |
GetColourScheme |
Get the current colour scheme. |
GetFlags |
Get the previously set style flags. |
GetFont |
Get the value of a certain font setting. |
GetGalleryClientSize |
Calculate the client size of a RibbonGallery control for a given size. |
GetGallerySize |
Calculate the size of a RibbonGallery control for a given client size. |
GetMetric |
Get the value of a certain integer setting. |
GetMinimisedPanelMinimumSize |
Calculate the size of a minimised ribbon panel. |
GetPageBackgroundRedrawArea |
Calculate the portion of a page background which needs to be redrawn when a page |
GetPanelClientSize |
Calculate the client size of a panel for a given overall size. |
GetPanelExtButtonArea |
Retrieve the extension button area rectangle. |
GetPanelSize |
Calculate the size of a panel for a given client size. |
GetScrollButtonMinimumSize |
Calculate the minimum size (in pixels) of a scroll button. |
GetTabCtrlHeight |
Calculate the height (in pixels) of the tab region of a ribbon bar. |
GetToolSize |
Calculate the size of a tool within a RibbonToolBar . |
ReallyDrawTabSeparator |
|
Reload |
|
RemovePanelPadding |
|
SetColour |
Set the value of a certain colour setting to the value. |
SetColourScheme |
Set all applicable colour settings from a few base colours. |
SetFlags |
Set the style flags. |
SetFont |
Set the value of a certain font setting to the value. |
SetMetric |
Set the value of a certain integer setting to the value. |
RibbonMSWArtProvider
(object)¶__init__
(self, set_colour_scheme=True)¶Clone
(self)¶Create a new art provider which is a clone of this one.
CloneTo
(self, copy)¶DrawButtonBarBackground
(self, dc, wnd, rect)¶Draw the background for a RibbonButtonBar
control.
Parameters: |
|
---|
DrawButtonBarButton
(self, dc, wnd, rect, kind, state, label, bitmap_large, bitmap_small)¶Draw a single button for a RibbonButtonBar
control.
Parameters: |
|
---|
DrawButtonBarButtonForeground
(self, dc, rect, kind, state, label, bitmap_large, bitmap_small)¶DrawDropdownArrow
(self, dc, x, y, colour)¶DrawGalleryBackground
(self, dc, wnd, rect)¶Draw the background and chrome for a RibbonGallery
control.
This should draw the border, brackground, scroll buttons, extension button, and any other UI elements which are not attached to a specific gallery item.
Parameters: |
|
---|
DrawGalleryBackgroundCommon
(self, dc, wnd, rect)¶DrawGalleryButton
(self, dc, rect, state, bitmaps)¶DrawGalleryItemBackground
(self, dc, wnd, rect, item)¶Draw the background of a single item in a RibbonGallery
control.
This is painted on top of a gallery background, and behind the items bitmap.
Unlike DrawButtonBarButton
and DrawTool
, it is not expected to draw the
item bitmap - that is done by the gallery control itself.
Parameters: |
|
---|
DrawMinimisedPanel
(self, dc, wnd, rect, bitmap)¶Draw a minimised ribbon panel.
Parameters: |
|
---|
DrawMinimisedPanelCommon
(self, dc, wnd, true_rect)¶DrawPageBackground
(self, dc, wnd, rect)¶Draw the background of a ribbon page.
Parameters: |
|
---|
See also
DrawPanelBackground
(self, dc, wnd, rect)¶Draw the background and chrome for a ribbon panel.
This should draw the border, background, label, and any other items of a panel
which are outside the client area of a panel. Note that when a panel is
minimised, this function is not called - only DrawMinimisedPanel
is called,
so a background should be explicitly painted by that if required.
Parameters: |
|
---|
DrawPanelBorder
(self, dc, rect, primary_colour, secondary_colour)¶DrawPartialPageBackground
(self, dc, wnd, rect, allow_hovered_or_page=True, offset=None, hovered=False)¶DrawPartialPageBackground1
(self, dc, wnd, rect, page, offset, hovered=False)¶DrawPartialPageBackground2
(self, dc, wnd, rect, allow_hovered=True)¶DrawScrollButton
(self, dc, wnd, rect_, style)¶Draw a ribbon-style scroll button.
Parameters: |
|
---|
DrawTab
(self, dc, wnd, tab)¶Draw a single tab in the tab region of a ribbon bar.
Parameters: |
|
---|
DrawTabCtrlBackground
(self, dc, wnd, rect)¶Draw the background of the tab region of a ribbon bar.
Parameters: |
|
---|
DrawTabSeparator
(self, dc, wnd, rect, visibility)¶Draw a separator between two tabs in a ribbon bar.
Parameters: |
|
---|
DrawTool
(self, dc, wnd, rect, bitmap, kind, state)¶Draw a single tool (for a RibbonToolBar
control).
Parameters: |
|
---|
DrawToolBarBackground
(self, dc, wnd, rect)¶Draw the background for a RibbonToolBar
control.
Parameters: |
|
---|
DrawToolGroupBackground
(self, dc, wnd, rect)¶Draw the background for a group of tools on a RibbonToolBar
control.
Parameters: |
|
---|
GetBarTabWidth
(self, dc, wnd, label, bitmap, ideal=None, small_begin_need_separator=None, small_must_have_separator=None, minimum=None)¶Calculate the ideal and minimum width (in pixels) of a tab in a ribbon bar.
Parameters: |
|
---|
GetButtonBarButtonSize
(self, dc, wnd, kind, size, label, bitmap_size_large, bitmap_size_small, button_size=None, normal_region=None, dropdown_region=None)¶Calculate the size of a button within a RibbonButtonBar
.
Parameters: |
|
---|---|
Returns: |
|
GetColour
(self, id)¶Get the value of a certain colour setting.
can be one of the colour values of RibbonArtSetting.
Parameters: | id – the colour id. |
---|
GetColourScheme
(self, primary, secondary, tertiary)¶Get the current colour scheme.
Returns three colours such that if SetColourScheme
were called with them, the
colour scheme would be restored to what it was when SetColourScheme
was last
called. In practice, this usually means that the returned values are the three
colours given in the last call to SetColourScheme
, however if
SetColourScheme
performs an idempotent operation upon the colours it is given
(like clamping a component of the colour), then the returned values may not be
the three colours given in the last call to SetColourScheme
.
If SetColourScheme
has not been called, then the returned values should result
in a colour scheme similar to, if not identical to, the default colours of the
art provider. Note that if SetColour
is called, then GetColourScheme
does
not try and return a colour scheme similar to colours being used - it’s return
values are dependant upon the last values given to SetColourScheme
, as
described above.
Parameters: |
|
---|
GetFlags
(self)¶Get the previously set style flags.
GetFont
(self, id)¶Get the value of a certain font setting.
can be one of the font values of RibbonArtSetting.
Parameters: | id – the font id. |
---|
GetGalleryClientSize
(self, dc, wnd, size, client_offset=None, scroll_up_button=None, scroll_down_button=None, extension_button=None)¶Calculate the client size of a RibbonGallery
control for a given size.
This should act as the inverse to GetGallerySize
, and decrement the given
size by enough to fir the gallery border, buttons, and other chrome.
Parameters: |
|
---|
GetGallerySize
(self, dc, wnd, client_size)¶Calculate the size of a RibbonGallery
control for a given client size.
This should increment the given size by enough to fit the gallery border, buttons, and any other chrome.
Parameters: |
|
---|
See also
GetMetric
(self, id)¶Get the value of a certain integer setting.
can be one of the size values of RibbonArtSetting.
Parameters: | id – a metric id. |
---|
GetMinimisedPanelMinimumSize
(self, dc, wnd, desired_bitmap_size=None, expanded_panel_direction=None)¶Calculate the size of a minimised ribbon panel.
Parameters: |
|
---|
GetPageBackgroundRedrawArea
(self, dc, wnd, page_old_size, page_new_size)¶Calculate the portion of a page background which needs to be redrawn when a page is resized.
To optimise the drawing of page backgrounds, as small an area as possible should be returned. Of couse, if the way in which a background is drawn means that the entire background needs to be repainted on resize, then the entire new size should be returned.
Parameters: |
|
---|
GetPanelClientSize
(self, dc, wnd, size, client_offset=None)¶Calculate the client size of a panel for a given overall size.
This should act as the inverse to GetPanelSize
, and decrement the given size
by enough to fit the panel label and other chrome.
Parameters: |
|
---|
See also
GetPanelExtButtonArea
(self, dc, wnd, rect)¶Retrieve the extension button area rectangle.
Parameters: |
|
---|
GetPanelSize
(self, dc, wnd, client_size, client_offset=None)¶Calculate the size of a panel for a given client size.
This should increment the given size by enough to fit the panel label and other chrome.
Parameters: |
|
---|
See also
GetScrollButtonMinimumSize
(self, dc, wnd, style)¶Calculate the minimum size (in pixels) of a scroll button.
Parameters: |
|
---|
GetTabCtrlHeight
(self, dc, wnd, pages)¶Calculate the height (in pixels) of the tab region of a ribbon bar.
Note that as the tab region can contain scroll buttons, the height should be greater than or equal to the minimum height for a tab scroll button.
Parameters: |
|
---|
GetToolSize
(self, dc, wnd, bitmap_size, kind, is_first, is_last, dropdown_region=None)¶Calculate the size of a tool within a RibbonToolBar
.
Parameters: |
|
---|
ReallyDrawTabSeparator
(self, wnd, rect, visibility)¶Reload
(self, setting)¶RemovePanelPadding
(self, rect)¶SetColour
(self, id, colour)¶Set the value of a certain colour setting to the value.
can be one of the colour values of RibbonArtSetting, though not all colour settings will have an affect on every art provider.
Parameters: |
|
---|
See also
SetColourScheme
(self, primary, secondary, tertiary)¶Set all applicable colour settings from a few base colours.
Uses any or all of the three given colours to create a colour scheme, and then sets all colour settings which are relevant to the art provider using that scheme. Note that some art providers may not use the tertiary colour for anything, and some may not use the secondary colour either.
Parameters: |
|
---|
See also
SetFlags
(self, flags)¶Set the style flags.
Normally called automatically by RibbonBar.SetArtProvider()
with the ribbon
bar’s style flags, so that the art provider has the same flags as the bar which
it is serving.
Parameters: | flags – MISSING DESCRIPTION. |
---|
SetFont
(self, id, font)¶Set the value of a certain font setting to the value.
can be one of the font values of RibbonArtSetting.
Parameters: |
|
---|
SetMetric
(self, id, new_val)¶Set the value of a certain integer setting to the value.
can be one of the size values of RibbonArtSetting.
Parameters: |
|
---|