Qt-interest Archive, December 2007
Menu usage
Message 1 in thread
Ok, this should be a RTFM, but manual and google searching have so far
failed to turn up the answer. So if someone can point me to the proper
documentation or something, it would be appreciated.
I am developing an application in Qt 4.3.3 on Mac OS X 10.5. I have
created in my code a global (no parent) menu bar with a number of
menus and actions. I am trying to figure out how to associate some
code with those actions. What object will receive the signals - I
would assume the active window, is this correct? What are the signals
named? When I make a menu bar in the designer, I can connect slots to
the menu signals with functions such as on_menu_command_triggered(),
but trying this with my programatically generated menus/actions
doesn't seem to work- am I just getting the signal names wrong?
Incidentally, what will happen to the global menu if I try compiling
on Windows- will it show up in all windows like it does on mac? Ok, I
could try it and find out, but I'm not quite to that point yet :) As
always, thanks for any assistance that you are willing to offer!
-----------------------------------------------
Israel Brewster
Computer Support Technician
Frontier Flying Service Inc.
5245 Airport Industrial Rd
Fairbanks, AK 99709
(907) 450-7250 x293
-----------------------------------------------
--
[ signature omitted ]
Message 2 in thread
On Dec 13, 2007, at 10:27 AM, Israel Brewster wrote:
> Ok, this should be a RTFM, but manual and google searching have so
> far failed to turn up the answer. So if someone can point me to the
> proper documentation or something, it would be appreciated.
Yep, I was right about the RTFM :-P. I just had to connect the action
as I created it, to whatever object I want. Not sure how I missed
that. Sorry for wasting your time and bandwidth.
-----------------------------------------------
Israel Brewster
Computer Support Technician
Frontier Flying Service Inc.
5245 Airport Industrial Rd
Fairbanks, AK 99709
(907) 450-7250 x293
-----------------------------------------------
>
>
> I am developing an application in Qt 4.3.3 on Mac OS X 10.5. I have
> created in my code a global (no parent) menu bar with a number of
> menus and actions. I am trying to figure out how to associate some
> code with those actions. What object will receive the signals - I
> would assume the active window, is this correct? What are the
> signals named? When I make a menu bar in the designer, I can connect
> slots to the menu signals with functions such as
> on_menu_command_triggered(), but trying this with my programatically
> generated menus/actions doesn't seem to work- am I just getting the
> signal names wrong?
>
>
> Incidentally, what will happen to the global menu if I try compiling
> on Windows- will it show up in all windows like it does on mac? Ok,
> I could try it and find out, but I'm not quite to that point yet :)
> As always, thanks for any assistance that you are willing to offer!
>
> -----------------------------------------------
> Israel Brewster
> Computer Support Technician
> Frontier Flying Service Inc.
> 5245 Airport Industrial Rd
> Fairbanks, AK 99709
> (907) 450-7250 x293
> -----------------------------------------------
>
>
> --
> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx
> with "unsubscribe" in the subject or the body.
> List archive and information: http://lists.trolltech.com/qt-interest/
--
[ signature omitted ]