85 DontFallbackMode = 0x01,
86 RegardPaddingsAsSize = 0x02
88 Q_DECLARE_FLAGS(IconMatchedFlags, IconMatchedFlag)
89 Q_FLAGS(IconMatchedFlags);
92 explicit DDciIcon(
const DCORE_NAMESPACE::DDciFile *dciFile);
93 explicit DDciIcon(
const QString &fileName);
94 explicit DDciIcon(
const QByteArray &data);
103 DDciIconMatchResult matchIcon(
int size, Theme theme, Mode mode, IconMatchedFlags flags = None)
const;
105 int actualSize(DDciIconMatchResult result)
const;
106 int actualSize(
int size, Theme theme, Mode mode = Normal)
const;
108 QList<int> availableSizes(Theme theme, Mode mode = Normal)
const;
109 bool isSupportedAttribute(DDciIconMatchResult result, IconAttibute attr)
const;
110 static bool isSupportedAttribute(
const DDciIconImage &image, IconAttibute attr);
112 QPixmap pixmap(qreal devicePixelRatio,
int iconSize, Theme theme, Mode mode = Normal,
114 QPixmap pixmap(qreal devicePixelRatio,
int iconSize, DDciIconMatchResult result,
117 void paint(QPainter *painter,
const QRect &rect, qreal devicePixelRatio, Theme theme, Mode mode = Normal,
119 void paint(QPainter *painter,
const QRect &rect, qreal devicePixelRatio, DDciIconMatchResult result,
122 DDciIconImage image(DDciIconMatchResult result,
int size, qreal devicePixelRatio)
const;
124 static DDciIcon fromTheme(
const QString &name);
129 QSharedDataPointer<DDciIconPrivate> d;
130#ifndef QT_NO_DATASTREAM
131 friend QDataStream &operator<<(QDataStream &,
const DDciIcon &);
132 friend QDataStream &operator>>(QDataStream &,
DDciIcon &);