diff options
author | Jens Bache-Wiig <jens.bache-wiig@digia.com> | 2012-09-18 13:55:45 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2012-09-27 15:16:16 +0200 |
commit | 570ae40f57f048d53ed32d035804746a11489f48 (patch) | |
tree | c0e70a04ed0a37cca52098d91a7ee5b5c74bb9e5 /examples/widgets/doc | |
parent | 05978af3a161ed0d830e67a1220e7d2ae47d8938 (diff) |
Remove CDE and Motif styles from qtbase
It is time to clean up some of our legacy code. These styles have
not been actively maintained for a long time and I think it is safe
to say that they should no longer belong as part of the default
distribution of Qt. We dont support any platforms based on CDE with
our source packages.
Note that even if we are removing these styles from the default
distribution of Qt, applications that depend on them
will still be able to bundle the existing (and unmodified) styles
along with their own source code as we are not breaking compatibility.
Change-Id: I1709630c20ba8e8088cd01628628d86856db57a4
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
Diffstat (limited to 'examples/widgets/doc')
-rw-r--r-- | examples/widgets/doc/src/application.qdoc | 11 | ||||
-rw-r--r-- | examples/widgets/doc/src/icons.qdoc | 4 | ||||
-rw-r--r-- | examples/widgets/doc/src/styles.qdoc | 20 |
3 files changed, 14 insertions, 21 deletions
diff --git a/examples/widgets/doc/src/application.qdoc b/examples/widgets/doc/src/application.qdoc index 4d795099e4..ef6dabc33b 100644 --- a/examples/widgets/doc/src/application.qdoc +++ b/examples/widgets/doc/src/application.qdoc @@ -231,16 +231,9 @@ Just before we create the \uicontrol{Help} menu, we call QMenuBar::addSeparator(). This has no effect for most widget - styles (e.g., Windows and Mac OS X styles), but for Motif-based + styles (e.g., Windows and Mac OS X styles), but for some styles this makes sure that \uicontrol{Help} is pushed to the right - side of the menu bar. Try running the application with various - styles and see the results: - - \code - application -style=windows - application -style=motif - application -style=cde - \endcode + side of the menu bar. Let's now review the toolbars: diff --git a/examples/widgets/doc/src/icons.qdoc b/examples/widgets/doc/src/icons.qdoc index 04ae310ced..d39f104bf1 100644 --- a/examples/widgets/doc/src/icons.qdoc +++ b/examples/widgets/doc/src/icons.qdoc @@ -600,8 +600,8 @@ In particular we create the \c styleActionGroup based on the currently available GUI styles using QStyleFactory. QStyleFactory::keys() returns a list of valid keys, - typically including "windows", "motif", "cde", and - "plastique". Depending on the platform, "windowsxp" and + typically including "windows", "cleanlooks" and + "plastique". Depending on the platform, "windowsxp", "windowsvista", "gtk" and "macintosh" may be available. We create one action for each key, and adds the action to the diff --git a/examples/widgets/doc/src/styles.qdoc b/examples/widgets/doc/src/styles.qdoc index 1297356e6f..773c7a7677 100644 --- a/examples/widgets/doc/src/styles.qdoc +++ b/examples/widgets/doc/src/styles.qdoc @@ -42,7 +42,7 @@ reimplementing a few virtual functions. In this example, the custom style is called \c NorwegianWoodStyle - and derives from QMotifStyle. Its main features are the wooden + and derives from QWindowsStyle. Its main features are the wooden textures used for filling most of the widgets and its round buttons and comboboxes. @@ -56,7 +56,7 @@ The example consists of the following classes: \list - \li \c NorwegianWoodStyle inherits from QMotifStyle and implements + \li \c NorwegianWoodStyle inherits from QWindowsStyle and implements the Norwegian Wood style. \li \c WidgetGallery is a \c QDialog subclass that shows the most common widgets and allows the user to switch style @@ -69,8 +69,8 @@ \snippet widgets/styles/norwegianwoodstyle.h 0 - The public functions are all declared in QStyle (QMotifStyle's - grandparent class) and reimplemented here to override the Motif + The public functions are all declared in QStyle (QWindowsStyle's + grandparent class) and reimplemented here to override the Windows look and feel. The private functions are helper functions. \section1 NorwegianWoodStyle Class Implementation @@ -154,7 +154,7 @@ \image styles-disabledwood.png The Norwegian Wood style with disabled widgets Let's move on to the other functions reimplemented from - QMotifStyle: + QWindowsStyle: \snippet widgets/styles/norwegianwoodstyle.cpp 3 \snippet widgets/styles/norwegianwoodstyle.cpp 4 @@ -186,23 +186,23 @@ widgets are drawn and their size hint. Here, we return 8 as the width around a shown in a QComboBox, ensuring that there is enough place around the text and the arrow for the Norwegian Wood - round corners. The default value for this setting in the Motif + round corners. The default value for this setting in the Windows style is 2. We also change the extent of \l{QScrollBar}s, i.e., the height for a horizontal scroll bar and the width for a vertical scroll - bar, to be 4 pixels more than in the Motif style. This makes the + bar, to be 4 pixels more than in the Windows style. This makes the style a bit more distinctive. - For all other QStyle::PixelMetric elements, we use the Motif + For all other QStyle::PixelMetric elements, we use the Windows settings. \snippet widgets/styles/norwegianwoodstyle.cpp 9 \snippet widgets/styles/norwegianwoodstyle.cpp 10 The \l{QStyle::styleHint()}{styleHint()} function returns some - hints to widgets or to the base style (in our case QMotifStyle) - about how to draw the widgets. The Motif style returns \c true + hints to widgets or to the base style (in our case QWindowsStyle) + about how to draw the widgets. The Windows style returns \c true for the QStyle::SH_DitherDisabledText hint, resulting in a most unpleasing visual effect. We override this behavior and return \c false instead. We also return \c true for the |