From 1460b387008e3db22f650256ef6e9afe95adef13 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Mon, 26 Dec 2005 07:54:32 +0000 Subject: [PATCH] Also strip (_F) without a space --- ChangeLog | 2 +- ChangeLog.pre-2-10 | 2 +- gtk/gtktoolbar.c | 5 ++--- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7523f9a64a..9eb2694204 100644 --- a/ChangeLog +++ b/ChangeLog @@ -3,7 +3,7 @@ * README.in: Mention the stripping of (_F) suffixes. * gtk/gtktoolbar.c (_gtk_toolbar_elide_underscores): Strip a suffix of - the form " (_)", since this is the preferred way + the form "(_)", since this is the preferred way for some languages to indicate accelerators. (#323956, Yang Hong) * gtk/gtklabel.c (gtk_label_class_init): Add a gtk-label-select-on-focus diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 7523f9a64a..9eb2694204 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -3,7 +3,7 @@ * README.in: Mention the stripping of (_F) suffixes. * gtk/gtktoolbar.c (_gtk_toolbar_elide_underscores): Strip a suffix of - the form " (_)", since this is the preferred way + the form "(_)", since this is the preferred way for some languages to indicate accelerators. (#323956, Yang Hong) * gtk/gtklabel.c (gtk_label_class_init): Add a gtk-label-select-on-focus diff --git a/gtk/gtktoolbar.c b/gtk/gtktoolbar.c index 712b0e3c9e..29196215ee 100644 --- a/gtk/gtktoolbar.c +++ b/gtk/gtktoolbar.c @@ -4900,11 +4900,10 @@ _gtk_toolbar_elide_underscores (const gchar *original) if (s > 4) { - if (original[s - 5] == ' ' && - original[s - 4] == '(' && + if (original[s - 4] == '(' && original[s - 3] == '_' && original[s - 1] == ')') - q[-4] = '\0'; + q[-3] = '\0'; }