diff options
author | Volker Hilsheimer <volker.hilsheimer@qt.io> | 2020-04-08 13:16:54 +0200 |
---|---|---|
committer | Volker Hilsheimer <volker.hilsheimer@qt.io> | 2020-04-08 21:58:41 +0200 |
commit | 402e955db0e0f396c371669bc39367a0a7db02d1 (patch) | |
tree | 702d02316f17c2f1777c5e9a4ef468ac397f54b4 /src/widgets/kernel | |
parent | c8dea4a83337835323111b3372cf645b51d48edd (diff) |
QApplication: remove deprecated members for obsolete ColorSpec
Change-Id: Idf1f4fd34e22c0ecac50a030e709d90b46dd6145
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Diffstat (limited to 'src/widgets/kernel')
-rw-r--r-- | src/widgets/kernel/qapplication.cpp | 93 | ||||
-rw-r--r-- | src/widgets/kernel/qapplication.h | 5 |
2 files changed, 0 insertions, 98 deletions
diff --git a/src/widgets/kernel/qapplication.cpp b/src/widgets/kernel/qapplication.cpp index de12347b89..5dd24d1052 100644 --- a/src/widgets/kernel/qapplication.cpp +++ b/src/widgets/kernel/qapplication.cpp @@ -309,22 +309,6 @@ void QApplicationPrivate::createEventDispatcher() \sa QCoreApplication, QAbstractEventDispatcher, QEventLoop, QSettings */ -#if QT_DEPRECATED_SINCE(5, 8) -// ### fixme: Qt 6: Remove ColorSpec and accessors. -/*! - \enum QApplication::ColorSpec - \obsolete - - \value NormalColor the default color allocation policy - \value CustomColor the same as NormalColor for X11; allocates colors - to a palette on demand under Windows - \value ManyColor the right choice for applications that use thousands of - colors - - See setColorSpec() for full details. -*/ -#endif - /*! \fn QWidget *QApplication::topLevelAt(const QPoint &point) @@ -1144,83 +1128,6 @@ QStyle* QApplication::setStyle(const QString& style) return s; } -#if QT_DEPRECATED_SINCE(5, 8) -/*! - Returns the color specification. - \obsolete - - \sa QApplication::setColorSpec() -*/ - -int QApplication::colorSpec() -{ - return QApplication::NormalColor; -} - -/*! - Sets the color specification for the application to \a spec. - \obsolete - - This call has no effect. - - The color specification controls how the application allocates colors when - run on a display with a limited amount of colors, e.g. 8 bit / 256 color - displays. - - The color specification must be set before you create the QApplication - object. - - The options are: - \list - \li QApplication::NormalColor. This is the default color allocation - strategy. Use this option if your application uses buttons, menus, - texts and pixmaps with few colors. With this option, the - application uses system global colors. This works fine for most - applications under X11, but on the Windows platform, it may cause - dithering of non-standard colors. - \li QApplication::CustomColor. Use this option if your application - needs a small number of custom colors. On X11, this option is the - same as NormalColor. On Windows, Qt creates a Windows palette, and - allocates colors to it on demand. - \li QApplication::ManyColor. Use this option if your application is - very color hungry, e.g., it requires thousands of colors. \br - Under X11 the effect is: - \list - \li For 256-color displays which have at best a 256 color true - color visual, the default visual is used, and colors are - allocated from a color cube. The color cube is the 6x6x6 - (216 color) "Web palette" (the red, green, and blue - components always have one of the following values: 0x00, - 0x33, 0x66, 0x99, 0xCC, or 0xFF), but the number of colors - can be changed by the \e -ncols option. The user can force - the application to use the true color visual with the - \l{QApplication::QApplication()}{-visual} option. - \li For 256-color displays which have a true color visual with - more than 256 colors, use that visual. Silicon Graphics X - servers this feature, for example. They provide an 8 bit - visual by default but can deliver true color when asked. - \endlist - On Windows, Qt creates a Windows palette, and fills it with a color - cube. - \endlist - - Be aware that the CustomColor and ManyColor choices may lead to colormap - flashing: The foreground application gets (most) of the available colors, - while the background windows will look less attractive. - - Example: - - \snippet code/src_gui_kernel_qapplication.cpp 2 - - \sa colorSpec() -*/ - -void QApplication::setColorSpec(int spec) -{ - Q_UNUSED(spec) -} -#endif - /*! \property QApplication::globalStrut \brief the minimum size that any GUI element that the user can interact diff --git a/src/widgets/kernel/qapplication.h b/src/widgets/kernel/qapplication.h index 4ecfe64b60..8f8abab3aa 100644 --- a/src/widgets/kernel/qapplication.h +++ b/src/widgets/kernel/qapplication.h @@ -99,11 +99,6 @@ public: static QStyle *style(); static void setStyle(QStyle*); static QStyle *setStyle(const QString&); - enum ColorSpec { NormalColor=0, CustomColor=1, ManyColor=2 }; -#if QT_DEPRECATED_SINCE(5, 8) - QT_DEPRECATED static int colorSpec(); - QT_DEPRECATED static void setColorSpec(int); -#endif // QT_DEPRECATED_SINCE(5, 8) #if QT_DEPRECATED_SINCE(5, 0) QT_DEPRECATED static inline void setGraphicsSystem(const QString &) {} #endif |