[texworks] Shortcuts and accelerators

Stefan Löffler st.loeffler at gmail.com
Fri Apr 16 17:54:11 CEST 2010


Hi,

first I'd like to say a big "thanks" to Alain for dealing with the
accelerator key problem. I really appreciate this very much, but like
Jonathan I had little time recently - so sorry for not replying earlier.

Am 2010-04-16 17:32, schrieb Jonathan Kew:
> On 16 Apr 2010, at 16:28, Alain Delmotte wrote:
>   
>> NB. 2 When one changes in the preferences from, let say, French (system default) to English, one should not select the English just under French, but the one added at the end of the list (due to the .qm file??!!). So the accelerators are immediately active, if not you have to close and re-open TW.
>>     
> Hmmm.... that seems a bit confusing. I wonder if we can tidy up that behavior? I'll try to look into it.
>   

I agree that this should be simplified somehow.

But I also want to point out another issue that has been mentioned
repeatedly both on GC and here: customizable shortcuts. I don't have a
solution for the problem yet, but there are a few cornerstones that we
probably can't do without and that have wide-ranging consequences on all
actions (menu items, tool bar, etc.) in Tw. These are (IMO):
1) We need a list of all actions, including some logical grouping so
people know which action they are customizing (e.g. distinguish between
"Find" in TeXDocument vs. "Find" in PDFDocument).
2) We need translations for each action (so we can display them in the UI).
3) We need a (separate) list of shortcuts for each action.

All things considered, I think it is fairly difficult to create this
list on the fly. It may be possible to create it with a shell script
during each commit (similar to the SvnRev.h file) and embed it in the
application. I'm not sure how the grouping could be achieved in that
case, though, and how additional shortcuts that are not hard-coded in
the UI files could be added there. The list Alain uses for the manual is
a start, but we'd need a much more flexible approach for providing the
ability to customize the shortcuts from the UI.

One option is of course to move all actions out of the UI files into a
separate file which is then loaded dynamically on startup and installs
all menu/toolbar items etc. But of course this would mean major changes
to the current system, it would render the rather useful UI designer
pretty useless, and I don't know exactly how translations would work in
this context.

Any other ideas are very welcome.

-Stefan


More information about the texworks mailing list