[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: gEDA-user: Translations for gEDA 1.6.1....



On Wed, 2010-02-10 at 18:40 +0000, Peter Clifton wrote:
> On Wed, 2010-02-10 at 20:31 +0100, Carlos Nieves Ãnega wrote:
> > Hi Peter,
> > I was preparing the spanish translation, and found that (with gschem in
> > spanish) I can't access to the menu with Alt+letter. For example, Alt+F
> > and get to the gschem File menu. 
> > 
> > I checked this in the .po file, and there is a "File" instead of "_File"
> > string.
> 
> For some reasons, the root menus don't actually have accelerators! I
> figured it was best to try and sort out the mess which is "intra-menu"
> accelerators before looking to break more strings adding "_File".
> Accelerators.
> 
> Also, it appears not to work.. I tried it in en_GB.po, and got
> "_File" (literally) in my menu. Looks like there needs to be some
> code-changes associated with the top level menu accelerators.
> 
> > Does it work for you? Am I missing something?

Required code-change is this:

diff --git a/gschem/src/x_menus.c b/gschem/src/x_menus.c
index 80cb131..5b4a597 100644
--- a/gschem/src/x_menus.c
+++ b/gschem/src/x_menus.c
@@ -209,7 +209,7 @@ void get_main_menu(GtkWidget ** menubar)
     }
     
     menu_name = (char *) gettext(*raw_menu_name);
-    root_menu = gtk_menu_item_new_with_label (menu_name);
+    root_menu = gtk_menu_item_new_with_mnemonic (menu_name);
     /* do not free *raw_menu_name */
 
     /* no longer right justify the help menu since that has gone out of style *


I think that could go into 1.6.1, to fix accelerator support for root
menus. I don't propose to change upstream menu strings in such a way as
to break existing translations though...

For example, "Edit" is used in a couple of places, so to add the
accelerator - we really need to use "_Edit" as the msgid, so the
translation is specific to the menu case.

If we changed the root menu strings at this point, I'd be inclined to
auto-update the fuzzy translations it creates, such as,

msgid "File"
msgstr "ãããã"

Becomes:

msgid "_File"
msgstr "ãããã"

(Or perhaps)

msgid "_File"
msgstr "ãããã(_F)"


The previous change (fixing rc_strings.c) at least didn't break any
existing translated parts of the interface. Changing the root menu
strings would unless we update the translations. Hopefully if we do
that, translators will come along - realise, and fix the root menu
accelerators.


Best regards,

Peter C.




_______________________________________________
geda-user mailing list
geda-user@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-user