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 f= ollowing line to ~/.bashrc: + * export QT_MESSAGE_PATTERN=3D"`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 =3D tr= ue")); =