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

Key Class

The QPixmapCache::Key class can be used for efficient access to the QPixmapCache.

Article lu   fois.

L'auteur

Liens sociaux

Viadeo Twitter Facebook Share on Google+   

Key Class

  • Header: Key

  • CMake:

    find_package(Qt6 REQUIRED COMPONENTS Gui)

    target_link_libraries(mytarget PRIVATE Qt6::Gui)

  • qmake: QT += gui

Detailed Description

Use QPixmapCache::insert() to receive an instance of Key generated by the pixmap cache. You can store the key in your own objects for a very efficient one-to-one object-to-pixmap mapping.

Member Function Documentation

 

Key::Key()

Constructs an empty Key object.

Key::~Key()

Destroys the key.

[since 5.7] bool Key::isValid() const

Returns true if there is a cached pixmap associated with this key. Otherwise, if pixmap was flushed, the key is no longer valid.

This function was introduced in Qt 5.7.

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