Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
updating UI while in debugger
mzimmers last edited by
Hi all -
When debugging a UI in single step mode, I often find the UI doesn't update until I hit the "run" button. Can this behavior be altered?
afaik the ui is updated when the eventloop runs.
As a hacky workaround, you could add
QCoreApplication::processEventsinside the code block you want to debug, that should, in theory, update your ui.
JonB last edited by JonB
Just so you know, all debuggers on all platforms (have to) work like this when debugging a UI-event-driven application. When stepping/running to next breakpoint, it executes only the instructions it comes across, and while they do not allow the UI to process events/repaint the visuals will remain "frozen". It actually shows you what what is really going on in your app!
Like @J-Hilk says, only way is temporarily to insert necessary event processing lines into the code you happen to be stepping through. Not ideal for debugging, but a standard issue.
negar2000 Banned last edited by negar2000
This post is deleted!