From 67a54bf4ef8fd164cbd76bd5d1e98c053a5fe7bf Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Thu, 22 Oct 2015 14:31:06 -0400 Subject: shortcuts: Support ranges in the display of shortcuts Repeating Alt-1 to Alt-9 as individual shortcuts looks really boring, so allow compressing such ranges by specifying 1...9. --- gtk/gtkshortcutsshortcut.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'gtk/gtkshortcutsshortcut.c') diff --git a/gtk/gtkshortcutsshortcut.c b/gtk/gtkshortcutsshortcut.c index c14eb0a455..b77b8bd178 100644 --- a/gtk/gtkshortcutsshortcut.c +++ b/gtk/gtkshortcutsshortcut.c @@ -185,9 +185,14 @@ gtk_shortcuts_shortcut_class_init (GtkShortcutsShortcutClass *klass) * The accelerator(s) represented by this object, in the syntax * understood by gtk_accelerator_parse(). Multiple accelerators * can be specified by separating them with a space, but keep in - * mind that the available width is limited. + * mind that the available width is limited. It is also possible + * to specify ranges of shortcuts, using ... between the keys. * - * Here is an example: ? F1 + * Examples: + * + * - A single shortcut: delete + * - Two alternative shortcuts: a Home + * - A range: 1...9 * * Note that < and > need to escaped as < and > when used * in .ui files. -- cgit v1.2.1