Re: help: using a shortcut to drop down the file menu



Thanks. But I'm trying to write an application for an iPAQ (hand held computer). There is no Alt key on the iPAQ. I'm going to map the file menu to one of the buttons on the ipaq latter, but to do that I need to be able to use a regular key on the keyboard of my desktop machine.

Steve.



Iago Rubio wrote:

On Thu, 2004-03-25 at 04:17, Steven Daniel Webb wrote:
newbie question.

When the user presses a key (such as 'm') I want to drop down the file menu, but I can't figure out how to do this. I've tried using accelerator keys. They work great for activating menu items, but I couldn't get the file menu to drop down.


Use gtk_menu_item_new_with_mnemonic():

menuitem_file = gtk_menu_item_new_with_mnemonic ("_File");

Then "Alt + f" should drop down your menu.

Using,  gtk_menu_item_new_with_mnemonic ("Fi_le")  , as example, the
trigger will be "Alt + l".
I mean, the underscore marks the character that used with the "Alt" key,
will drop down your menu.
------------------------------------------------------------------------

!DSPAM:4062aa6e118911016978178!






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