Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
QIconEngine::ScaledPixmapArgument Class Reference

#include <qiconengine.h>

+ Collaboration diagram for QIconEngine::ScaledPixmapArgument:

Public Attributes

QSize size
 
QIcon::Mode mode
 
QIcon::State state
 
qreal scale
 
QPixmap pixmap
 

Detailed Description

Since
5.9

\inmodule QtGui

This struct represents arguments to the virtual_hook() function when the id parameter is QIconEngine::ScaledPixmapHook.

The struct provides a way for icons created via \l QIcon::fromTheme() to return pixmaps that are designed for the current \l {High DPI}{device pixel ratio}. The scale for such an icon is specified using the \l {Icon Theme Specification - Directory Layout}{Scale directory key} in the appropriate index.theme file.

Icons created via other approaches will return the same result as a call to \l pixmap() would, and continue to benefit from Qt's \l {High Resolution Versions of Images}{"@nx" high DPI syntax}.

See also
virtual_hook(), QIconEngine::IconEngineHook, {High DPI Icons}

Definition at line 40 of file qiconengine.h.

Member Data Documentation

◆ mode

QIcon::Mode QIconEngine::ScaledPixmapArgument::mode

Definition at line 43 of file qiconengine.h.

◆ pixmap

QPixmap QIconEngine::ScaledPixmapArgument::pixmap

Definition at line 46 of file qiconengine.h.

◆ scale

qreal QIconEngine::ScaledPixmapArgument::scale

Definition at line 45 of file qiconengine.h.

◆ size

QSize QIconEngine::ScaledPixmapArgument::size

Definition at line 42 of file qiconengine.h.

◆ state

QIcon::State QIconEngine::ScaledPixmapArgument::state

Definition at line 44 of file qiconengine.h.


The documentation for this class was generated from the following file: