Hi
His the a recent version of http://developer.kde.org/language-bi...-manual-3.html for me to learn how to create main windows?
I am looking for an example using QT Designer or even better .... Qt Creator.
Thanks
Hi
His the a recent version of http://developer.kde.org/language-bi...-manual-3.html for me to learn how to create main windows?
I am looking for an example using QT Designer or even better .... Qt Creator.
Thanks
Ok, first let's make one thing straight - Qt Creator uses Qt Designer internally so everything that goes with Designer, goes with Creator as well.
Second of all QMainWindow docs will give you all you need to create a main window and its subcomponents.
How to use them and Designer itself is described here: Qt Designer Manual. Pay special attention to "Using Qt Designer" and "Using Forms and Components" sections.
I've been here already.
Has i pointed out in the link above, what i am looking for i more like an how to complete example, and then use the links you gave me as source for understanding some specific specific situations.
Most of the documentation found on the web assumes that everyone is a great programmer with deep Knowledge of Qt classes ...
I guess Qt comunity could start investing more in that area.
Simple an small examples for those o are thinking of using Qt ... or send them back to VB or other stuff like that
Just a sugestion.
gt.beta2 (21st February 2009)
That's more like it
In the examples the commented lines like ...
//! [35]
... are for?
Hello,
I've been reading this example: http://doc.trolltech.com/4.4/mainwin...plication.html.
What if i wanted to use Qt Designer with Qt Creator MainWindow template!
When we go to Project > Qt4 GUI Application > create a MainWindow project we get some thing like this:
main.cpp
mainwindow.hQt Code:
#include <QtGui/QApplication> #include "mainwindow.h" int main(int argc, char *argv[]) { MainWindow w; w.show(); return a.exec(); }To copy to clipboard, switch view to plain text mode
mainwindow.cppQt Code:
#ifndef MAINWINDOW_H #define MAINWINDOW_H #include <QtGui/QMainWindow> namespace Ui { class MainWindowClass; } { Q_OBJECT public: ~MainWindow(); private: Ui::MainWindowClass *ui; }; #endif // MAINWINDOW_HTo copy to clipboard, switch view to plain text mode
Qt Code:
#include "mainwindow.h" #include "ui_mainwindow.h" { ui->setupUi(this); } MainWindow::~MainWindow() { delete ui; }To copy to clipboard, switch view to plain text mode
If now i want to reuse the code of the example without the Qt Designer ... where showld i start?!
Guess this is a more complex inheritance scheme ... but i would like to use it.
Thaks for the more patient ones
found this ...
http://doc.trolltech.com/qtcreator-0...g-program.html
Looks like a starting point.
Let's make one thing straight. A "main window" is by no means different than a "regular" window/dialog/widget. It just has additional capabilities in regards to what is inside the window, so everything that applies to a "regular" widget, applies to a "main window" widget as well.
Designer reads and writes UI files that have a .ui extension. Now try guessing which files from the ones created by Creator or whatever else tool anyone might have been using might be opened with Designer.
Have you read the "Using Forms and Components" section of Designer docs or did you only have a glimpse of it? If the latter then go back and read with understanding what is written there. All your questions can be answered just by reading and understanding the first part of that section of documentation.
When I started on Qt, I found that I didn't need to stray any further than the Qt Assistant doco to learn how things work. You need to spend time reading the doco, it's VERY important. Work through the tutorials contained in the doco as well.
Yes ... you are right.
I was in "kind of a hurry" but i guess i definitely need some reading
Thanks all .... "I'll be back"
Ok then.
I've been trough the The Direct Approach, The Single Inheritance Approach and The Multiple Inheritance Approach.
Guess that each one as it's own application filed.
The third one seems more comfortable to use, although it says that "...but does not conveniently support composition of multiple user interfaces".
When i use Qt Creator to start a project based on QDialog class (for instance) it uses single inheritance ... right!
Can i ask why? Is it because of what i said above, and this way the template will cover all situations?
Hope this is not another stupid question
Bookmarks