diff options
author | Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> | 2018-09-03 14:02:13 +0200 |
---|---|---|
committer | Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> | 2018-10-15 10:55:18 +0000 |
commit | 1f6bfc220774e9407fe88916843b76ed103cff72 (patch) | |
tree | 8d6157d5b974e6045d75a716f8eb0db4daefa35f /src/corelib/io/qloggingcategory.cpp | |
parent | 02a214442781bf112c1cc85d2470c6fcec8ed207 (diff) |
Doc: Move literal code block to a separate file
We need to override this snippet for the documentation
we generate for Qt for Python, and it is easier to have
it on a separate file.
Task-number: PYSIDE-801
Task-number: PYSIDE-691
Change-Id: Ideb5b6af25024279f167137d3b65660bb9c96a7e
Reviewed-by: Topi Reiniƶ <topi.reinio@qt.io>
Diffstat (limited to 'src/corelib/io/qloggingcategory.cpp')
-rw-r--r-- | src/corelib/io/qloggingcategory.cpp | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/src/corelib/io/qloggingcategory.cpp b/src/corelib/io/qloggingcategory.cpp index aa84f56368..33253429a2 100644 --- a/src/corelib/io/qloggingcategory.cpp +++ b/src/corelib/io/qloggingcategory.cpp @@ -135,9 +135,7 @@ static void setBoolLane(QBasicAtomicInt *atomic, bool enable, int shift) flexible way. Rules are specified in text, where every line must have the format - \code - <category>[.<type>] = true|false - \endcode + \snippet code/src_corelib_io_qloggingcategory.cpp 0 \c <category> is the name of the category, potentially with \c{*} as a wildcard symbol as the first or last character (or at both positions). @@ -149,10 +147,7 @@ static void setBoolLane(QBasicAtomicInt *atomic, bool enable, int shift) Rules can be set via \l setFilterRules(): - \code - QLoggingCategory::setFilterRules("*.debug=false\n" - "driver.usb.debug=true"); - \endcode + \snippet code/src_corelib_io_qloggingcategory.cpp 1 Since Qt 5.3, logging rules are also automatically loaded from the \c [Rules] section of a logging @@ -160,19 +155,13 @@ static void setBoolLane(QBasicAtomicInt *atomic, bool enable, int shift) configuration directory, or explicitly set in a \c QT_LOGGING_CONF environment variable: - \code - [Rules] - *.debug=false - driver.usb.debug=true - \endcode + \snippet code/src_corelib_io_qloggingcategory.cpp 2 Since Qt 5.3, logging rules can also be specified in a \c QT_LOGGING_RULES environment variable. And since Qt 5.6, multiple rules can also be separated by semicolons: - \code - QT_LOGGING_RULES="*.debug=false;driver.usb.debug=true" - \endcode + \snippet code/src_corelib_io_qloggingcategory.cpp 3 Rules set by \l setFilterRules() take precedence over rules specified in the QtProject configuration directory, and can, in turn, be |