File indexing completed on 2026-09-26 09:09:51
0001
0002
0003
0004
0005 #ifndef QCOLORMAP_H
0006 #define QCOLORMAP_H
0007
0008 #include <QtWidgets/qtwidgetsglobal.h>
0009 #include <QtGui/qrgb.h>
0010 #include <QtGui/qwindowdefs.h>
0011 #include <QtCore/qatomic.h>
0012 #include <QtCore/qlist.h>
0013
0014 QT_BEGIN_NAMESPACE
0015
0016 class QColor;
0017 class QColormapPrivate;
0018
0019 #if QT_REMOVAL_QT7_DEPRECATED_SINCE(6, 11)
0020 class Q_WIDGETS_EXPORT QT_DEPRECATED_VERSION_6_11 QColormap
0021 {
0022 public:
0023 enum Mode { Direct, Indexed, Gray };
0024
0025 static void initialize();
0026 static void cleanup();
0027
0028 static QColormap instance(int screen = -1);
0029
0030 QColormap(const QColormap &colormap);
0031 ~QColormap();
0032
0033 QColormap &operator=(const QColormap &colormap);
0034
0035 Mode mode() const;
0036
0037 int depth() const;
0038 int size() const;
0039
0040 uint pixel(const QColor &color) const;
0041 const QColor colorAt(uint pixel) const;
0042
0043 const QList<QColor> colormap() const;
0044
0045 private:
0046 QColormap();
0047 QColormapPrivate *d;
0048 };
0049 #endif
0050
0051 QT_END_NAMESPACE
0052
0053 #endif