https://issues.apache.org/ooo/show_bug.cgi?id=122640

--- Comment #2 from Ariel Constenla-Haile <[email protected]> ---
(In reply to Andrea Pescetti from comment #0)
> Created attachment 80950 [details]
> Menus in Italian 4.0 dev snapshot
> 
> We've been telling translators that they can ignore "~" in translated
> strings (corresponding to keyboard accelerator, e.g., ALT-F-O to open a
> file, not to be confused with shortcuts, like CTRL-O, that are fine),
> following historical information.
> 
> This indeed works for the internal menu items (it seems that accelerators
> are assigned correctly), 

In most cases, yes; but not in general:

- New Impress document
- menu "~View" - "Sidebar" has no mnemonic character assigned.

This is a regression introduced by some change in the vcl code, may be in the
way to Oracle 3.4 beta or before. In 3.0.0 (old version I have at hand),
mnemonic are generated always:

- New Writer document
- Tools - Customize - Menus
- Add a new top level menu "New menu"
- Add the following menu items:

abc
abc
abc
abc
abc
abc

Save the changes, and open the new menubar's PopupMenu:

- in 3.0.0 you get

~abc
a~bc
ab~c
~abc
~abc
~abc

The algorithm was not perfect, but it was working. One could expect a desirable
result of:

~abc
a~bc
ab~c
~abc
a~bc
ab~c

instead of the first letter as mnemonic when all letters are already taken.

- in 3.4.1 you get

~abc
a~bc
ab~c
abc
abc
abc

The regression here is visible: it's better to have repeated mnemonics than no
mnemonic at all.

> but not for the main menu items.

Automatic mnemonics were never generated for the top level menu bar items, only
for the its PopupMenus.

This could be added to the code (if possible - I'll have to check), and it
would be useful for the case of user-customized menus (when the user customizes
the menubar s/he has no idea about mnemonic character ~, so the new menubar
item ends up without mnemonic).

But for the OpenOffice menubar, using automatic mnemonic generation will end up
on the same top level menubar items having different mnemonic across the
different applications.

> It would probably be good to fix at least the main menu in OpenOffice 4.0
> final.

IMO, for the top level menubar items, the only fix is to set the mnemonic
character in the translation. This should be already in the translation memory,
in officecfg/registry/data/org/openoffice/Office/UI.po
For example, ".uno:PickList" was in 3.4.* in two places:

https://translate.apache.org/es/OOo_34/translate.html#search=uno_PickList&sfields=locations
GenericCommands.xcu#..GenericCommands.UserInterface.Popups..uno_PickList.Label.value.text
StartModuleCommands.xcu#..StartModuleCommands.UserInterface.Popups..uno_PickList.Label.value.text

In 4.0.0 all commands with the same label were moved to GenericCommands.xcu, so
now there is only one string to translate:
https://translate.apache.org/es/aoo40/translate.html#search=uno_PickList&sfields=locations

For example, in the 4.0.0 Spanish translation, the Window menubar item has no
accelerator:
https://translate.apache.org/es/aoo40/translate.html#search=uno_WindowList&sfields=locations
The translator should pick a translation memory suggestion.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to