Re: [Frogface-general] Adding Menus to the GUI
Status: Planning
Brought to you by:
declanmcgrath
|
From: Declan M. <dec...@fr...> - 2007-04-29 04:09:58
|
Hi Ganesh, I would call the menu "Help" and it would contain the following items - Frogface Manual (this is a link to http://www.frogface.org/wiki/pmwiki.php?n=Main.UserGuide) (tooltip: "Frogface Manual") - Frogface.org (tooltip: "The Frogface.org website in all it's glory!") - <separator> - About (this would just be a QMessageBox which pops up a text string saying "Frogface is an open source scuba dive log with a mission to bring you a fast, fun, featureful dive log to capture your undersea adventures! It is licenced under the GNU Public Licence (GPL) Version 2, 1991. If it happens in the sea, log in in Frogface!" This is just a rough draft, we can come up with something more fancy later. So to answer your question, I think we should have a help menu which will pop up an about menu. By the way, there's probably no easy way at the moment for you to call a browser so for the first 2 links just pop up a QMessageBox which lists the web address. Again, we'll come up with something better later. Enjoy! Dec On Sunday 29 April 2007 04:32, you wrote: > Hi Declan, > > I got your email through frogface mailing list.Then, to our menu, I will > call it as FroggieMainWindow as you said me before. Ok.. Then, I have some > work to do, I guess.. I will let you know if I've any other queries. > > Well, while making this email. I got one.. What's the content to be > displayed in 'about' menu.. Also, shall I make just an 'about' menu or a > 'help' menu which pops out a 'about' menu? > > You really did a good work by deploying a website for froggie... Keep > going!!! > > Cheers, > Ganesh. > > On 4/28/07, Declan McGrath <dec...@fr...> wrote: > > Hi Ganesh, > > > > Finally got around to taking a proper look at your email. Had a bit of a > > crazy > > week at work. You gotta hate deadlines but I guess they're a necessary > > evil! > > > > I'm (obviously!) posting this to the frogface mailing list. I hope that > > this > > list will work ok - This is effectively the first testing of this mailing > > list since I switched web hosting companies. So there may be some > > teething problems with this list. > > > > Anyway, I think your suggestion to inherit from QMainWindow is the best > > approach. Perhaps call the inherited class something like > > FroggieMainWindow - > > I was going to suggest calling it DiveDashboardMainWindow but I think we > > have > > enough confusing DiveDashboard classes already! Then you should be able > > to implement the about() functionality like you said. Is this ok? > > > > Regards, > > Dec > > > > On Saturday 28 April 2007 23:33, you wrote: > > > Hi Dec, > > > > > > A few doubts, > > > > > > *Shall I create a new class mainwindow which inherits QMainWindow and > > > keep all the main window things like about() in it? Or should I keep > > > it within main() all these things? > > > > > > If you want me to do it within main().Then, all those examples given > > > in QT are used by creating new classes. Can you tell me any > > > suggestions for it? > > > I guess, if I paste the code till what I did might give an idea of > > > what I'm actually asking you for.. > > > > > > Here's the code: > > > QMenu *menu = mainWin.menuBar()->addMenu(QObject::tr("&File")); > > > menu->addAction(QObject::tr("&Quit"), &app, SLOT(quit())); > > > menu->addSeparator(); > > > QMenu *helpMenu = mainWin.menuBar()->addMenu(QObject::tr("&Help")); > > > helpMenu->addAction(QObject::tr("&About"), &app, SLOT(about())); > > > > > > So, the Quit works fine. Also, A help menu is created which pops out > > > an 'about' menu but for that function, where should that QMessageBox > > > be present? > > > > > > Normally in the examples given, They have created a class which > > > inherits QMainWindow and then created an about() in which QMessageBox > > > is given.So, when in above code, about() is called, it invokes that > > > function and displays the message. > > > > > > Thanks, > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by DB2 Express > > Download DB2 Express C - the FREE version of DB2 express and take > > control of your XML. No limits. Just data. Click to get it now. > > http://sourceforge.net/powerbar/db2/ > > _______________________________________________ > > Frogface-General mailing list > > Fro...@li... > > https://lists.sourceforge.net/lists/listinfo/frogface-general |