diff options
author | Matthias Clasen <mclasen@redhat.com> | 2015-12-04 13:16:35 -0500 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2015-12-04 13:22:26 -0500 |
commit | 03769e3830ca3c8ab8265ac1a52d4000e52409d9 (patch) | |
tree | fe8c97d9506e3cb5886455b33b1a236bb1c8d503 /gtk/gtkshortcutlabel.c | |
parent | 27b24bb68f859f4115175c109dc89c091b468408 (diff) | |
download | gtk+-03769e3830ca3c8ab8265ac1a52d4000e52409d9.tar.gz |
shortcut label: Tweak modifier key rendering
The subscript was affecting the vertical alignment too much,
so tweak the rendering of the L/R markers to avoid that. Also,
mark these as translatable.
Diffstat (limited to 'gtk/gtkshortcutlabel.c')
-rw-r--r-- | gtk/gtkshortcutlabel.c | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/gtk/gtkshortcutlabel.c b/gtk/gtkshortcutlabel.c index ef7d462822..5cb7f06c37 100644 --- a/gtk/gtkshortcutlabel.c +++ b/gtk/gtkshortcutlabel.c @@ -60,7 +60,12 @@ get_modifier_label (guint key) case GDK_KEY_Meta_L: case GDK_KEY_Super_L: case GDK_KEY_Hyper_L: - subscript = "L"; + /* Translators: This string is used to mark left/right variants of modifier + * keys in the shortcut window (e.g. Control_L vs Control_R). Please keep + * this string very short, ideally just a single character, since it will + * be rendered as part of the key. + */ + subscript = C_("keyboard side marker", "L"); break; case GDK_KEY_Shift_R: case GDK_KEY_Control_R: @@ -68,7 +73,12 @@ get_modifier_label (guint key) case GDK_KEY_Meta_R: case GDK_KEY_Super_R: case GDK_KEY_Hyper_R: - subscript = "R"; + /* Translators: This string is used to mark left/right variants of modifier + * keys in the shortcut window (e.g. Control_L vs Control_R). Please keep + * this string very short, ideally just a single character, since it will + * be rendered as part of the key. + */ + subscript = C_("keyboard side marker", "R"); break; default: g_assert_not_reached (); @@ -98,7 +108,7 @@ get_modifier_label (guint key) g_assert_not_reached (); } - return g_strdup_printf ("%s<sub>%s</sub>", label, subscript); + return g_strdup_printf ("%s <small><b>%s</b></small>", label, subscript); } static gchar ** |