Variable: AdwShortcutLabel
constAdwShortcutLabel:"AdwShortcutLabel"
Defined in: generated/jsx.ts:19254
A widget that displays a keyboard shortcut.

The shown shortcut can be set using the ShortcutLabel.accelerator property.
Optionally, if no shortcut is set, AdwShortcutLabel will display a
placeholder set with the ShortcutLabel.disabled-text property.
The following types of shortcuts can be displayed:
-
A single shortcut in Gtk.accelerator_parse format, e.g.
<Control>C:
-
Multiple alternative shortcuts, separated with spaces, e.g.
<Shift>A Home:
-
A range of shortcuts, separated with
..., e.g.<Alt>1...9:
-
Multiple keys pressed at once, separated with
&, e.g.Control_L&Control_R:
-
Multiple shortcuts or keys, pressed sequentially, separated with
+, e.g.<Control>C+<Control>X:
::: note
<, > and & need to be escaped as <, > and & when used in UI files.
CSS nodes
AdwShortcutLabel has a single CSS node with name shortcut-label. The
individual keycap labels each have the .keycap style class, while the
labels separating them have the .dimmed style class.
Accessibility
AdwShortcutLabel uses the GTK_ACCESSIBLE_ROLE_LABEL role.
See also: ShortcutsDialog.