textual_wrapper.types
Base classes for the wrapper.
Classes:
|
An option in the menubar or the right click menu of the launcher/taskbar icon. |
|
A wrapper around a terminal app. |
-
namedtuple
MenuOption(label, keypress)[source] Bases:
NamedTupleAn option in the menubar or the right click menu of the launcher/taskbar icon.
- Fields
-
__repr__() Return a nicely formatted representation string
-
class
Wrapper(name, arguments, icon=None, launcher_options=<factory>, menu_options=<factory>)[source] Bases:
ABCA wrapper around a terminal app.
Methods:
__eq__(other)Return self==value.
__repr__()Return repr(self).
add_launcher_option(option)Add an option to the launcher/taskbar icon.
add_menu_option(option[, group])Add an option to the menubar at the top of the window.
run([working_directory])Launch the wrapper.
Attributes:
The executable and command line arguments.
Optional icon filename.
List of right click options for the launcher/taskbar icon.
Options for the menubar.
The name of the application.
-
__eq__(other) Return self==value.
-
__repr__() Return repr(self).
-
add_launcher_option(option)[source] Add an option to the launcher/taskbar icon.
- Parameters
option (
MenuOption)
Add an option to the menubar at the top of the window.
- Parameters
option (
MenuOption)group (
str) – The top level button, e.g.File,Edit,Help. Default'File'.
-
launcher_options Type:
list[MenuOption]List of right click options for the launcher/taskbar icon.
Type:
dict[str,list[MenuOption]]Options for the menubar.
-