[Development] QLog ( Work on qDebug and friends)

wolfgang.beck at nokia.com wolfgang.beck at nokia.com
Wed Feb 22 01:37:40 CET 2012

Why you want to use the categories somewhere else then QLog?
You want to reinvent a mechanism to filter the categories then?
If you don't filter what sense makes having the categories?
I mean you still have qDebug and you can write whatever you like.


-----Original Message-----
From: Koehne Kai (Nokia-MP/Berlin) 
Sent: Tuesday, February 21, 2012 8:20 PM
To: ext David Faure
Cc: Beck Wolfgang (Nokia-MP/Brisbane); development at qt-project.org
Subject: RE: [Development] QLog ( Work on qDebug and friends)

> -----Original Message-----
> From: ext David Faure [mailto:david.faure at kdab.com]
> Sent: Tuesday, February 21, 2012 11:08 AM
> To: Koehne Kai (Nokia-MP/Berlin)
> Cc: Beck Wolfgang (Nokia-MP/Brisbane); development at qt-project.org
> Subject: Re: [Development] QLog ( Work on qDebug and friends)
> On Tuesday 21 February 2012 10:02:23 kai.koehne at nokia.com wrote:
> > I agree with that: On the desktop it's quite handy to see also 
> > detailed output on stderr/the shell (which one can redirect to a 
> > file if
> needed).
> > But I also think that qLog() messages shouldn't show up by default 
> > for normal users, that is, unless the category has been explicitly enabled.
> True.
> > So how about adding another QtMsgType called QLogMsg, that qLog() 
> > uses? In contrast to qDebug/QtDebugMsg, qLog/QtLogMsg messages
> would
> > not be processed by default, unless the configuration file (or an 
> > environment
> > variable) says so ...
> Isn't the same information given by "a category is present in the 
> QMessageLogContext"? All qLog calls are forced to get a category, right?

Right, but that would mean we can't use categories for anything except qLog. If we use categories solely for the purpose of filtering that's probably fine, but I personally also see some value in having them available as free text in the log, for all log QtMsgType's ...



> --
> David Faure | david.faure at kdab.com | KDE/Qt Senior Software Engineer 
> KDAB (France) S.A.S., a KDAB Group company Tel. France +33 (0)4 90 84 
> 08 53, Sweden (HQ) +46-563-540090 KDAB - Qt Experts - 
> Platform-independent software solutions

More information about the Development mailing list