Gtk.ShortcutLabel
Class Details
- 
class Gtk.ShortcutLabel(*args, **kwargs)
- 
Gtk.ShortcutLabelis a widget that represents a single keyboard shortcut or gesture
in the user interface.
 
- 
classmethod new(accelerator)[source]
- 
Creates a new Gtk.ShortcutLabelwith accelerator set.
 
 
- 
get_accelerator()[source]
- 
| Returns: | the current accelerator. | 
|---|
 | Return type: | strorNone | 
|---|
 
 - Retrieves the current accelerator of self. 
 
- 
get_disabled_text()[source]
- 
| Returns: | the current text displayed when no
accelerator is set. | 
|---|
 | Return type: | strorNone | 
|---|
 
 - Retrieves the text that is displayed when no accelerator is set. 
 
- 
set_accelerator(accelerator)[source]
- 
| Parameters: | accelerator ( str) – the new accelerator | 
|---|
 
 - Sets the accelerator to be displayed by self. 
 
- 
set_disabled_text(disabled_text)[source]
- 
| Parameters: | disabled_text ( str) – the text to be displayed when no accelerator is set | 
|---|
 
 - Sets the text to be displayed by self when no accelerator is set. 
 
 
Property Details
- 
Gtk.ShortcutLabel.props.accelerator
- 
The accelerator that self displays. See Gtk.ShortcutsShortcut:acceleratorfor the accepted syntax.
 
- 
Gtk.ShortcutLabel.props.disabled_text
- 
The text that is displayed when no accelerator is set.