On 11/26/05, Daniel Pekelharing <[EMAIL PROTECTED]> wrote: > Only it doesn't seem to work for me? > I even tried gtk_rc_parse_string("gtk-can-change-accels = 1"); > > Perhaps it's because I have a manually constructed menu? > Do you know if menu withinit only works with UI manager?
Hi again, It works with hand-made menus too. You need to have an accel group and path for each item. I make one accel group per top-level window, then attach each item in that window which might have an accelerator to that group. The path names each item (eg. "<main_window>/File/Open") soGTK can save and restore accelerators correctly. Here's my app's code for menu items: http://cvs.sourceforge.net/viewcvs.py/vips/nip2-7.11/src/toolview.c?rev=1.1.1.1&view=markup and for menus: http://cvs.sourceforge.net/viewcvs.py/vips/nip2-7.11/src/toolkitview.c?rev=1.1.1.1&view=markup There's more stuff in there for building menu trees which hang off UI manager trees, don't know if that's useful for you. John _______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list