[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: [umbrello/frameworks] umbrello/debug: Setting the debug message pattern.
From: Andi Fischer <andi.fischer () hispeed ! ch>
Date: 2015-04-30 22:10:09
Message-ID: E1Ynwen-0004C3-Mc () scm ! kde ! org
[Download RAW message or body]
Git commit bf9761b1d7cbd07f4c2ead246caf61af38a32afc by Andi Fischer.
Committed on 29/04/2015 at 14:39.
Pushed by fischer into branch 'frameworks'.
Setting the debug message pattern.
M +5 -0 umbrello/debug/debug_utils.cpp
http://commits.kde.org/umbrello/bf9761b1d7cbd07f4c2ead246caf61af38a32afc
diff --git a/umbrello/debug/debug_utils.cpp b/umbrello/debug/debug_utils.cpp
index 0dc1521..cf30013 100644
--- a/umbrello/debug/debug_utils.cpp
+++ b/umbrello/debug/debug_utils.cpp
@@ -40,11 +40,16 @@ Tracer* Tracer::instance()
/**
* Constructor.
+ * The debug message pattern can be changed by adding something like the following \
line to ~/.bashrc: + * export QT_MESSAGE_PATTERN="`echo -e \
"%{appname}(%{pid})/(%{category}) \
\033[31m%{if-debug}\033[34m%{endif}%{function}\033[0m: %{message}"`" + *
* @param parent the parent widget
*/
Tracer::Tracer(QWidget *parent)
: QTreeWidget(parent)
{
+ qSetMessagePattern(QStringLiteral("%{appname} \
\033\[31m%{if-debug}\033\[32m%{endif}%{function}\033\[0m: %{message}")); +
//TODO: can be removed in Qt 5.3
QLoggingCategory::setFilterRules(QStringLiteral("umbrello.debug = true"));
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic