On 4/21/21 2:59 PM, Ted Felix wrote:
On 4/21/21 3:44 AM, David Faure wrote:
qDebug/qCDebug can be turned off at compile time with
QT_NO_DEBUG_OUTPUT, which we could decide to set in release builds.

 That is *exactly* what I need.  I need the performance hit removed in
release builds.  If someone wants debug logging, they can do a debug
build.

 Can QT_NO_DEBUG_OUTPUT also be used on a file-by-file basis when we
are done working in a file, but afraid we might have to revisit?  I
assume it would be stronger than filtering since it would remove the
performance hit.

The documentation says: "The macro expands to code that checks whether
QLoggingCategory::isDebugEnabled
<https://doc.qt.io/qt-5/qloggingcategory.html#isDebugEnabled>()
evaluates to |true|. If so, the stream arguments are processed and sent
to the message handler.". In other words - there is no performance hit.
Debugging can be left active in the code - if there is no config file
setting logging active for a certain category it is the same as the
NO_DEBUG compile option.


Well, sure, if the goal is to use qCDebug to do *exactly the same
thing* as
the current solution, then nothing is gained, and my time is better
spent
elsewhere.

 What we have currently works for me.  If you can add some benefit,
great.  But I need it to work *exactly as it does currently* for
numerous reasons.  I spent a lot of time tweaking this to get the
current results and avoid angering anyone else who didn't want their
logging removed.  So, I'd rather move on than revisit logging.

Fair enough. But I think there are significant benefits to category
logging. I always have to turn logging on then test - and not forget to
turn the logging off again afterwards. Much easier with a logging config
file


IMHO the biggest benefit is to cut down on all the "noise" by default
and let
people enable the debug categories they're interested in.

 Sounds like a great improvement.  But let's also keep the original
behavior as an option.  Since that is what I need to do my job.  If
you guys feel all this work is worth it and you can give me what I
need, then be my guest.

I believe you will get essentially the original behaviour but if we
start converting files to category logging you will have to use the
config file to get what you want.


Ted.


_______________________________________________
Rosegarden-devel mailing list
Rosegarden-devel@lists.sourceforge.net - use the link below to
unsubscribe
https://lists.sourceforge.net/lists/listinfo/rosegarden-devel

_______________________________________________
Rosegarden-devel mailing list
Rosegarden-devel@lists.sourceforge.net - use the link below to unsubscribe
https://lists.sourceforge.net/lists/listinfo/rosegarden-devel

Reply via email to