[Qt-interest] About Application menu item via Qt project.
Israel Brewster
israel at frontierflying.com
Fri Jul 17 18:43:53 CEST 2009
On Jul 17, 2009, at 2:48 AM, Arnold Krille wrote:
> Hi,
>
> On Friday 17 July 2009 10:17:18 Manish Chaturvedi wrote:
>> I am working on a Qt/Mac application. I want to display the Version
>> and
>> other information of my application by clicking Menu "My
>> Application"->
>> "About MyApplication" but I cannot see any such menu in my
>> application.
>> Whereas when we create any Cocoa application it is provided by
>> default with
>> Application menu. Is there is any way to get this menu via Qt
>> application?
>
> First advice: Teach your users not to double-click.
>
> Second advice: Make the forms/dialogs ignore all clicks for the
> first 500ms
> after showing/creation. Maybe by "setEnabled( false )" followed by
> "setEnabled( true )". I think these also propagate to all
> subwidgets, so it
> should be save to do this on the main-widget alone.
>
> Dealing with the mouse-clicks yourself will get very complicated.
How does that have to do with an "About myApplication" menu item
*grin*? The good news though: getting this menu item is easy enough:
you simply need to add a menu item titled "About <whatever>" into one
of your menus. As long as it starts with "About", Qt will recognize it
and move it into the Application menu for you. See the QMenuBar
documentation (http://doc.trolltech.com/4.5/qmenubar.html#details)
specifically the section titled "QMenuBar on Mac OS X". Typically I
would add this menu item to a Help menu, as that would make sense on
other platforms as well. Of course, you will still be responsible for
making something happen when that menu item is selected, but Qt can
make this easy as well: see http://doc.trolltech.com/4.5/qmessagebox.html#about
. Although personally, I prefer to make the about dialog myself so I
can have a bit more control over its appearance.
-----------------------------------------------
Israel Brewster
Computer Support Technician II
Frontier Flying Service Inc.
5245 Airport Industrial Rd
Fairbanks, AK 99709
(907) 450-7250 x293
-----------------------------------------------
>
> Have fun,
>
> Arnold
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Israel Brewster.vcf
Type: text/directory
Size: 397 bytes
Desc: not available
Url : http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090717/bb862665/attachment.bin
More information about the Qt-interest-old
mailing list