Re: menu accelerators not working



On 10/30/07, Philip Tricca <phil noggle biz> wrote:
> >> I'm using the GtkUIManager to build my menus from GtkActionEntrys and
> >> an
> >> xml description.  Everything works great except for the accelerators.
> >> I
> >> can't seem to get them working at all, even the stock quit.

Have you added the accel group to the window? You need:

        accel_group = gtk_ui_manager_get_accel_group( mainw->ui_manager );
        gtk_window_add_accel_group( GTK_WINDOW( mainw ), accel_group );

For example, search in:

http://vips.svn.sourceforge.net/viewvc/vips/nip2/trunk/src/program.c?view=markup

for accel for some boilerplate.

John


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