Radek
6th May 2013, 18:24
I need some pointers. What I want to reach: create UI using a resource editor (Qt designer here) and write the code myself. I do not want "automatically generated code" anywhere. I would like to keep control on what I am writing. I am more familiar with wxWidgets so what I would do in wxWidgets:
(1) Start with an empty wxWidgets project.
(2) Create an .XRC file (in Qt, this should be an .UI file) in wxFormBuilder (in Qt, this should be Qt Designer).
(3) Write the code. Load the XRC in the main window ctor, get pointers to subordinated widgets, connect, write connect handlers and so on.
(4) When the app is ready (the UI can change many times in between), embed the UI into the executable along with resources (icons, pictures, other static data).
Back to Qt. I can start with an empty project and create a simple window without the Designer. I would like to start using Designer but where to begin? I tried "New File -> Qt -> Main Window" from the Creator and I got a "panel" without a titlebar. Starting a stand alone Designer, I really got a main window. The main window seems to already contain a grid sizer but when I do not want it (box sizer is enough)? Is it possible to start creating the UI from the Creator and let the Creator to handle project dependencies? I would like the following:
(1) Start with an empty Qt project, fill in base info (template, target, QT) - I am able of it.
(2) Start Designer from the Creator and create the UI script - how exactly?
(3) Write the code. Load the UI in the main window ctor - I have seen some snippets that seem to be usable.
(4) When the app is ready, embed UI and resources in the executable - this is far away and not important now but I am keeping in mind that I will do it later.
(1) Start with an empty wxWidgets project.
(2) Create an .XRC file (in Qt, this should be an .UI file) in wxFormBuilder (in Qt, this should be Qt Designer).
(3) Write the code. Load the XRC in the main window ctor, get pointers to subordinated widgets, connect, write connect handlers and so on.
(4) When the app is ready (the UI can change many times in between), embed the UI into the executable along with resources (icons, pictures, other static data).
Back to Qt. I can start with an empty project and create a simple window without the Designer. I would like to start using Designer but where to begin? I tried "New File -> Qt -> Main Window" from the Creator and I got a "panel" without a titlebar. Starting a stand alone Designer, I really got a main window. The main window seems to already contain a grid sizer but when I do not want it (box sizer is enough)? Is it possible to start creating the UI from the Creator and let the Creator to handle project dependencies? I would like the following:
(1) Start with an empty Qt project, fill in base info (template, target, QT) - I am able of it.
(2) Start Designer from the Creator and create the UI script - how exactly?
(3) Write the code. Load the UI in the main window ctor - I have seen some snippets that seem to be usable.
(4) When the app is ready, embed UI and resources in the executable - this is far away and not important now but I am keeping in mind that I will do it later.