From bc05a1b6dfe49ab192c3eb47f9edf3e3bc8a2861 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kai=20K=C3=B6hne?= Date: Fri, 14 Oct 2022 11:16:36 +0200 Subject: Doc: qdoc doesn't accept wildcard C++ defines anymore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Since the switch to clang, qdoc cannot process wildcard based defines anymore. Update documentation accordingly. Change-Id: I3e1bf3234e17bcd46cbb4c2bd72ea33ad188fc9c Reviewed-by: Luca Di Sera Reviewed-by: Topi Reiniƶ (cherry picked from commit 5e51e1f8eddd1cd01c3ec96eb48e290608cbb3b0) Reviewed-by: Qt Cherry-pick Bot --- src/qdoc/doc/qdoc-manual-qdocconf.qdoc | 21 +++------------------ 1 file changed, 3 insertions(+), 18 deletions(-) diff --git a/src/qdoc/doc/qdoc-manual-qdocconf.qdoc b/src/qdoc/doc/qdoc-manual-qdocconf.qdoc index b618e08f6..52d7fb9dc 100644 --- a/src/qdoc/doc/qdoc-manual-qdocconf.qdoc +++ b/src/qdoc/doc/qdoc-manual-qdocconf.qdoc @@ -264,34 +264,19 @@ enclose documentation that only will be included if the preprocessor symbol is defined. - The values of the variable are regular expressions (see QRegularExpression - for details). By default, no symbol is defined, meaning that code - protected with #ifdef...#endif will be ignored. - \badcode - defines = Q_QDOC \ - QT_.*_SUPPORT \ - QT_.*_LIB \ - QT_COMPAT \ - QT3_SUPPORT \ - Q_OS_.* \ - Q_BYTE_ORDER \ - __cplusplus + defines = QT_GUI_LIB \endcode This ensures that QDoc will process the code that requires these symbols to be defined. For example: \code - #ifdef Q_OS_WIN - HDC getDC() const; - void releaseDC(HDC) const; + #ifdef Q_GUI_LIB + void keyClick(QWidget *widget, Qt::Key key, Qt::KeyboardModifiers modifier = Qt::NoModifier, int delay = -1) #endif \endcode - Since the Q_OS_.* regular expression (specified using the \c - defines variable) matches Q_OS_WIN, QDoc will process the code - within #ifdef and #endif in our example. You can also define preprocessor symbols manually on the command line using the -D option. For example: -- cgit v1.2.1