pycrossword
0.4
Pure-Python implementation of a crossword puzzle generator and editor
|
Wrapper class for the application main window (pycross::gui::MainWindow). More...
Public Member Functions | |
def | __init__ (self, mainwindow) |
Constructor takes a single parameter - the instance of pycross::gui::MainWindow (main window). More... | |
def | trigger_action (self, action_name, display_name=True) |
Triggers an action of the app main window. More... | |
def | global_options (self, option=None, option_sep='/') |
Returns a pointer to the global options dict guisettings::CWSettings::settings. More... | |
def | get_prop (self, propname, default=None) |
Getter method for the main window members by their name. More... | |
def | __getattr__ (self, attr) |
Private Attributes | |
__mainwindow | |
pycross::gui::MainWindow internal pointer to app main window instance More... | |
Wrapper class for the application main window (pycross::gui::MainWindow).
Adds a few convenience methods to call the main app actions, query and set global settings, etc. TODO: Must think of a more protected way to expose the main window's methods and members.
def pycross.utils.pluginmanager.PxAPI.__init__ | ( | self, | |
mainwindow | |||
) |
Constructor takes a single parameter - the instance of pycross::gui::MainWindow (main window).
def pycross.utils.pluginmanager.PxAPI.__getattr__ | ( | self, | |
attr | |||
) |
def pycross.utils.pluginmanager.PxAPI.get_prop | ( | self, | |
propname, | |||
default = None |
|||
) |
Getter method for the main window members by their name.
propname | str member name (property or method) |
default | the default value if the member wasn't found (default = None ) |
def pycross.utils.pluginmanager.PxAPI.global_options | ( | self, | |
option = None , |
|||
option_sep = '/' |
|||
) |
Returns a pointer to the global options dict guisettings::CWSettings::settings.
def pycross.utils.pluginmanager.PxAPI.trigger_action | ( | self, | |
action_name, | |||
display_name = True |
|||
) |
Triggers an action of the app main window.
action_name | str object name or display text of the action to be called |
display_name | bool True if the display text is passed, otherwise, the action will be located by its object (variable) name |
|
private |
pycross::gui::MainWindow
internal pointer to app main window instance