Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. updating UI while in debugger
Forum Updated to NodeBB v4.3 + New Features

updating UI while in debugger

Scheduled Pinned Locked Moved Solved Qt Creator and other tools
4 Posts 4 Posters 679 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • mzimmersM Offline
    mzimmersM Offline
    mzimmers
    wrote on last edited by
    #1

    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?

    Thanks...

    J.HilkJ JonBJ 2 Replies Last reply
    0
    • mzimmersM mzimmers

      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?

      Thanks...

      J.HilkJ Offline
      J.HilkJ Offline
      J.Hilk
      Moderators
      wrote on last edited by
      #2

      @mzimmers
      afaik the ui is updated when the eventloop runs.

      As a hacky workaround, you could add QCoreApplication::processEvents inside the code block you want to debug, that should, in theory, update your ui.


      Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct


      Q: What's that?
      A: It's blue light.
      Q: What does it do?
      A: It turns blue.

      1 Reply Last reply
      1
      • mzimmersM mzimmers

        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?

        Thanks...

        JonBJ Offline
        JonBJ Offline
        JonB
        wrote on last edited by JonB
        #3

        @mzimmers
        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.

        1 Reply Last reply
        1
        • N Offline
          N Offline
          negar2000
          Banned
          wrote on last edited by negar2000
          #4
          This post is deleted!
          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved