diff options
author | David Robillard <d@drobilla.net> | 2016-08-01 03:43:23 -0400 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2016-08-01 03:44:00 -0400 |
commit | 902703efa9425a0630053c10229de911e23a2a43 (patch) | |
tree | 078b44cf205f8f7a3265142ff95b36f08f56fa05 /src/Log.cpp | |
parent | ff6d8a87f9569a42c7827428f2329280c9b633b9 (diff) | |
download | ingen-902703efa9425a0630053c10229de911e23a2a43.tar.gz ingen-902703efa9425a0630053c10229de911e23a2a43.tar.bz2 ingen-902703efa9425a0630053c10229de911e23a2a43.zip |
Show colorized log output in messages window
Diffstat (limited to 'src/Log.cpp')
-rw-r--r-- | src/Log.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/Log.cpp b/src/Log.cpp index b2d30b7d..46b88aec 100644 --- a/src/Log.cpp +++ b/src/Log.cpp @@ -98,7 +98,11 @@ int Log::vtprintf(LV2_URID type, const char* fmt, va_list args) { int ret = 0; - if (_log) { + if (type == _uris.log_Trace && !_trace) { + return 0; + } else if (_sink) { + ret = _sink(type, fmt, args); + } else if (_log) { ret = _log->vprintf(_log->handle, type, fmt, args); } else if (type == _uris.log_Error) { ColorContext ctx(stderr, ColorContext::Color::RED); |