Handle both Level and Category
Currently, level and category cannot be handled simultaneously.
dtkLogEnginePrivate::dtkLogEnginePrivate(dtk::LogLevel lev, bool cust) : level(lev), category(nullptr), stream(&buffer), custom(cust)
{
write = [this]() { this->writeLevel(); };
}
dtkLogEnginePrivate::dtkLogEnginePrivate(dtk::LogLevel lev, const QLoggingCategory& cat) : level(lev), category(&(const_cast<QLoggingCategory&>(cat))), stream(&buffer), custom(false)
{
write = [this]() { this->writeCategory(); };
}
Maybe it would be nice to gather them into the structured message as proposed in issue #1 (closed) .