Uranium
Application Framework
|
Central object responsible for running the main event loop and creating other central objects. More...
Public Member Functions | |
def | __init__ |
Init method. More... | |
def | addCommandLineOptions (self) |
def | parseCliOptions (self) |
def | initialize (self) |
def | startSplashWindowPhase (self) |
def | startPostSplashWindowPhase (self) |
def | run (self) |
Run the main event loop. More... | |
def | getContainerRegistry (self) |
def | getApplicationLockFilename (self) |
Get the lock filename. | |
def | setGlobalContainerStack |
def | getGlobalContainerStack (self) |
def | hideMessage |
def | showMessage |
def | showToastMessage |
def | getVersion (self) |
Get the version of the application. | |
def | getBuildType (self) |
Get the build type of the application. | |
def | getIsDebugMode (self) |
def | getIsHeadLess (self) |
def | getUseExternalBackend (self) |
def | hideMessageById |
Hide message by ID (as provided by built-in id function) | |
def | getVisibleMessages (self) |
Get list of all visible messages. | |
def | getApplicationName (self) |
Get name of the application. More... | |
def | getPreferences (self) |
Get the preferences. More... | |
def | savePreferences (self) |
def | getApplicationLanguage (self) |
Get the currently used IETF language tag. More... | |
def | getRequiredPlugins (self) |
Application has a list of plugins that it must have. More... | |
def | setRequiredPlugins |
Set the plugins that the application must have in order to function. More... | |
def | setBackend |
Set the backend of the application (the program that does the heavy lifting). More... | |
def | getBackend (self) |
Get the backend of the application (the program that does the heavy lifting). More... | |
def | getPluginRegistry (self) |
Get the PluginRegistry of this application. More... | |
def | getController (self) |
Get the Controller of this application. More... | |
def | getOperationStack (self) |
def | getOutputDeviceManager (self) |
def | getRenderer (self) |
Return an application-specific Renderer object. More... | |
def | functionEvent |
Post a function event onto the event loop. More... | |
def | callLater |
Call a function the next time the event loop runs. More... | |
def | getMainThread (self) |
Get the application's main thread. More... | |
def | addExtension |
def | getExtensions (self) |
def | getInstance (cls, args, kwargs) |
Static Public Member Functions | |
def | getInstallPrefix () |
Public Attributes | |
default_theme | |
change_log_url | |
Static Public Attributes | |
applicationShuttingDown = Signal() | |
Emitted when the application window was closed and we need to shut down the application. | |
showMessageSignal = Signal() | |
hideMessageSignal = Signal() | |
globalContainerStackChanged = Signal() | |
workspaceLoaded = Signal() | |
visibleMessageAdded = Signal() | |
visibleMessageRemoved = Signal() | |
Central object responsible for running the main event loop and creating other central objects.
The Application object is a central object for accessing other important objects. It is also responsible for starting the main event loop. It is passed on to plugins so it can be easily used to access objects required for those plugins.
def UM.Application.Application.__init__ | ( | self, | |
name | |||
) |
Init method.
name | string The name of the application. |
version | string Version, formatted as major.minor.rev |
build_type | Additional version info on the type of build this is, such as "master". |
is_debug_mode | Whether to run in debug mode. |
def UM.Application.Application.callLater | ( | self, | |
func | |||
) |
Call a function the next time the event loop runs.
You can't get the result of this function directly. It won't block.
function | The function to call. |
args | The positional arguments to pass to the function. |
kwargs | The keyword arguments to pass to the function. |
def UM.Application.Application.functionEvent | ( | self, | |
event | |||
) |
Post a function event onto the event loop.
This takes a CallFunctionEvent object and puts it into the actual event loop.
NotImplementedError |
def UM.Application.Application.getApplicationLanguage | ( | self, | |
str | |||
) |
Get the currently used IETF language tag.
The returned tag is during runtime used to translate strings.
def UM.Application.Application.getApplicationName | ( | self, | |
str | |||
) |
Get name of the application.
def UM.Application.Application.getBackend | ( | self, | |
Backend | |||
) |
def UM.Application.Application.getController | ( | self, | |
Controller | |||
) |
Get the Controller of this application.
def UM.Application.Application.getMainThread | ( | self, | |
threading, | |||
Thread | |||
) |
Get the application's main thread.
def UM.Application.Application.getPluginRegistry | ( | self, | |
PluginRegistry | |||
) |
Get the PluginRegistry of this application.
def UM.Application.Application.getPreferences | ( | self, | |
Preferences | |||
) |
Get the preferences.
def UM.Application.Application.getRenderer | ( | self, | |
Renderer | |||
) |
Return an application-specific Renderer object.
NotImplementedError |
def UM.Application.Application.getRequiredPlugins | ( | self, | |
List, | |||
str | |||
) |
Application has a list of plugins that it must have.
If it does not have these, it cannot function. These plugins can not be disabled in any way.
def UM.Application.Application.run | ( | self | ) |
Run the main event loop.
This method should be re-implemented by subclasses to start the main event loop.
NotImplementedError |
def UM.Application.Application.setBackend | ( | self, | |
backend | |||
) |
Set the backend of the application (the program that does the heavy lifting).
def UM.Application.Application.setRequiredPlugins | ( | self, | |
plugin_names | |||
) |
Set the plugins that the application must have in order to function.
plugin_names | list List of strings with the names of the required plugins |