On Fri, 28 Jan 2005 10:48:35 +0100 Gyözö Both <[EMAIL PROTECTED]> wrote:
> hello, > > i hope i'm not asking anything that's already been clarified before; the > archives of this list are huge and i couldn't find out whether this has been > asked before. > > i'm writing a gtk+2 application (the interface of which gets created by > glade), and i'd like to make use of this magnificent feature that allows > users to change the keyboard shortcuts by hovering on a menu entry with the > mouse and pressing the buttons. > > now i've tried to achieve this by creating a ~/.gtkrc-2.0 file containing > 'gtk-can-change-accels = 1' and also by setting the appropriate value to 1 > with 'gnome-conf'. it didn't work. then i tried to do a > > GtkSettings *settings = gtk_settings_get_default(); > g_object_set(settings, "gtk-can-change-accels", TRUE, NULL); I use the following code *after* I create the main menu: { GtkSettings* gtksettings = gtk_settings_get_default(); g_object_set(G_OBJECT(gtksettings), "gtk-can-change-accels", TRUE, NULL); gtk_accel_map_load(shortcutfilename); } it works, but I don't use glade regards, Olivier _______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list