IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)

Qt Core

The Qt Core module is part of Qt's essential modules.

Article lu   fois.

L'auteur

Liens sociaux

Viadeo Twitter Facebook Share on Google+   

Core Functionalities

Qt Core adds these features to C++:

  • a very powerful mechanism for seamless object communication called signals and slots

  • queryable and designable object properties

  • hierarchical and queryable object trees that organize

  • object ownership in a natural way with guarded pointers (QPointer)

  • a dynamic cast that works across library boundaries

The following pages provide more information about Qt's core features:

Using the Module

Using a Qt module requires linking against the module library, either directly or through other dependencies. Several build tools have dedicated support for this, including CMake and qmake.

Building with CMake

Use the find_package() command to locate the needed module components in the Qt5 package:

 
Sélectionnez
find_package(Qt5 COMPONENTS Core REQUIRED)
target_link_libraries(mytarget Qt5::Core)

See also the Building with CMake overview.

Building with qmake

If you use qmake to build your projects, Qt5Core is linked by default.

Threading and Concurrent Programming

Qt provides thread support in the form of platform-independent threading classes, a thread-safe way of posting events, and signal-slot connections across threads. Multithreaded programming is also a useful paradigm for performing time-consuming operations without freezing the user interface of an application.

The Thread Support in Qt page contains information on implementing threads in applications. Additional concurrent classes are provided by the Qt Concurrent module.

Input/Output, Resources, and Containers

Qt provides a resource system for organizing application files and assets, a set of containers, and classes for receiving input and printing output.

In addition, Qt Core provides a platform-independent mechanism for storing binary files in the application's executable.

Additional Frameworks

Licenses and Attributions

Qt Core is available under commercial licenses from The Qt Company. In addition, it is available under free software licenses. Since Qt 5.4, these free software licenses are GNU Lesser General Public License, version 3, or the GNU General Public License, version 2. See Qt Licensing for further details.

Executables on Windows potentially link against The qtmain Library. This library is available under commercial licenses and also under the BSD 3-clause "New" or "Revised" License.

Furthermore, Qt Core in Qt 5.13.2 may contain third party modules under following permissive licenses:

Reference

Vous avez aimé ce tutoriel ? Alors partagez-le en cliquant sur les boutons suivants : Viadeo Twitter Facebook Share on Google+