Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

QT overview/tutorial? [closed]

Tags:

c++

qt

Does anyone know of any good tutorials/articles which give a broad overview of QT? I'm not looking for a verbose "type this in and this is what it does" kind of tutorial (e.g. Nokia's/Troll Tech's tutorials, I can look at the api docs up for this stuff), but rather something which explains the thought process and considerations which go into making a QT app (for example, the idea of connecting signals to slots, what a widget is and isn't, how the API is organized, etc.).

like image 630
helloworld922 Avatar asked May 04 '11 04:05

helloworld922


People also ask

Is Qt deprecated?

The following Qt C++ classes are now obsolete. Obsolete classes are no longer maintained. They are provided to keep old source code working, but they can be removed in a future release. We strongly advise against using these classes in new code.

Is Qt good for C++?

For C++, the provided Qt Test framework gives basic testing functionality and is good for testing Qt flavoured C++ code (e.g. signals and slots).

Is Qt Creator better than Visual Studio?

Visual Assist. easier project file configuration and customization (qmake is way too limited in some areas) Visual Studio is my choice for C++ development (I'm used to it) Qt integration is not that good (IMHO)

Is Qt easy to learn?

The overall development effort is minimal since Qt API are easy to understand and application functionality can be implemented with a smaller amount of code. C++ experts will find a lot of powerful APIs and tools in Qt which will make complicated things simple and new features easy to get done.


2 Answers

I recommend reading the following conceptual documents from the Qt Documentation itself:

The Core

  • Object Model presents the why and how Qt extends the plain C++ object model with the metaobject compiler and what features it adds.
  • Object Trees and Ownership illustrates the preferred way of managing dynamically allocated QObjects in Qt. (Notice: preferred, not mandatory.)
  • Signals and Slots explains this basic concept in greater depth.
  • Container Classes presents the STL-compatible, collection-like classes adopted by the Qt API. An important concept, implicit sharing, is also introduced.
  • The Qt Resource System describes how data can be embedded in your program or library and accessed at runtime through a special file system.
  • You're doing it wrong is a blog post explaining how to properly use the QThread class. This is a good read because the documentation and all examples are wrong.
  • Debugging Techniques are a few debugging tips that are peculiar to Qt. In particular, it explains how to use the qDebug construct.

Here's the full list of core documents.

GUI and Graphics

  • Widgets and Layouts defines what widgets are and how they are assembled on the screen.
  • Window and Dialog Widgets explains the subtle difference between what Qt treats as windows and what it treats as widgets.
  • Layout Management goes into further detail about widget layout. If you use the built in UI designer, you'll rarely need to fiddle with layout classes directly, but the concepts are nevertheless important.
  • Paint System is how Qt draws stuff.
  • Coordinate System illustrates how Qt interprets graphics coordinates on painting devices.
  • Qt Quick is the new way of building pretty UIs.

Here's the full list of GUI and Graphics documents.

By the time you understand the basics, the rest of the API is very cohesive, consistent and easy to grasp.

like image 67
andref Avatar answered Nov 16 '22 00:11

andref


You can try C++ GUI Programming with QT4

like image 26
beduin Avatar answered Nov 16 '22 01:11

beduin