Why use QMainwindow?
-
wrote on 13 Mar 2015, 14:46 last edited by
Hello Dears,
i have a very general question since i´m still kind of a NewBe
(Be* NewBe = new Be(ROFL);What´s the reason to use QMainwindow?
What´s the difference compared to when i use a normal Widget, and place Dropdown and Menubuttons and arrange them by "setGeometry();"? -
wrote on 13 Mar 2015, 15:00 last edited by
QMainWindow offer Menu bar , tools bar, status bar and can contain a center widget .
-
Hello Dears,
i have a very general question since i´m still kind of a NewBe
(Be* NewBe = new Be(ROFL);What´s the reason to use QMainwindow?
What´s the difference compared to when i use a normal Widget, and place Dropdown and Menubuttons and arrange them by "setGeometry();"?wrote on 13 Mar 2015, 15:04 last edited byI'd say that QMainWindow provides you with a lot of the normal look and fell as one expects from applications. Since the list of methods not negligable compared to normal widget, it has quite some additional functionality.
If you do not need all those functionality and look and feel, you may inherit QWidget for your class. The question is how much you have to reimplement which is already there. However, it depends heavily on your targets. -
wrote on 13 Mar 2015, 22:04 last edited by
QMainWIndow
offers standard methods to manage MenuBar, ToolBars, StatusBar and Docks.IMO the most important feature is to manage them "natively" on different platform (i.e. on OSX the menu bar is on top of the screen and not in the Application Window
1/4