Matt Montag
Matt Montag

Reputation: 7481

Can I show qDebug() output in my Qt application?

I use qDebug() commands throughout my project to throw information to the Output box in Visual Studio. Is there a way to make the qDebug() stream display in a widget in my application, like a test mode/error console?

Upvotes: 0

Views: 3064

Answers (1)

hmuelner
hmuelner

Reputation: 8221

You can use qInstallMessageHandler to redirect the output of qDebug. For an example see the answer to the question "Custom and Default Message Handler in Qt"

Upvotes: 2

Related Questions