Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Visuals not refreshing without mouse movement
Forum Updated to NodeBB v4.3 + New Features

Visuals not refreshing without mouse movement

Scheduled Pinned Locked Moved Unsolved General and Desktop
12 Posts 4 Posters 1.6k Views 1 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.
  • Kent-DorfmanK Offline
    Kent-DorfmanK Offline
    Kent-Dorfman
    wrote on last edited by Kent-Dorfman
    #3

    my WAG is that you are stalling the event loop somewhere by doing procedural programming and not purely event driven. I've also seen problems like you describe because of memory leak/access problems with how heap managed GUI elements are handled.

    If you meet the AI on the road, kill it.

    PLL3P 1 Reply Last reply
    1
    • JoeCFDJ JoeCFD

      @PLL3 is this issue on touch screen? Do you call button->update() after it is enabled?

      PLL3P Offline
      PLL3P Offline
      PLL3
      wrote on last edited by
      #4

      @JoeCFD No, we do not support touch screens (if you're wondering why the cursor looks weird, it's because screenshot don't normally capture the cursor so I had to add them back).

      I don't believe I'm ever calling update() on any of my buttons, I haven't had an issue so far.

      1 Reply Last reply
      0
      • Kent-DorfmanK Kent-Dorfman

        my WAG is that you are stalling the event loop somewhere by doing procedural programming and not purely event driven. I've also seen problems like you describe because of memory leak/access problems with how heap managed GUI elements are handled.

        PLL3P Offline
        PLL3P Offline
        PLL3
        wrote on last edited by
        #5

        @Kent-Dorfman There is indeed a fair bit of calculation usually done in this panel, but like I said in my first post, I removed everything from that panel. There is nothing to load, to compute, so I'm not sure how I could stall that event loop you talk about.

        I'll look into the memory leak theory.

        Still, it somehow has to be related to the QGraphicsDropShadowEffect I apply to my topmost widget, since the bug appears and disappears depending on the blur radius. This is what puzzles me the most.

        JonBJ 1 Reply Last reply
        0
        • PLL3P PLL3

          @Kent-Dorfman There is indeed a fair bit of calculation usually done in this panel, but like I said in my first post, I removed everything from that panel. There is nothing to load, to compute, so I'm not sure how I could stall that event loop you talk about.

          I'll look into the memory leak theory.

          Still, it somehow has to be related to the QGraphicsDropShadowEffect I apply to my topmost widget, since the bug appears and disappears depending on the blur radius. This is what puzzles me the most.

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

          @PLL3 said in Visuals not refreshing without mouse movement:

          Still, it somehow has to be related to the QGraphicsDropShadowEffect I apply to my topmost widget, since the bug appears and disappears depending on the blur radius. This is what puzzles me the most.

          Indeed this appears to be key to your finding. And would not be common for other users.

          It seems really "strange" that this would affect behaviour in the way your report. It might be "coincidence", somehow.

          I am not understanding what this "topmost widget" is. Your screenshots show a rectangular widget on which all your text and buttons are placed. Is that your "topmost widget"?

          If this genuinely depends just on some drop shadow effect, you really should be able to reproduce a tiny, standalone example. If not it makes me wonder about what else in your code might be the cause.

          PLL3P 1 Reply Last reply
          1
          • JonBJ JonB

            @PLL3 said in Visuals not refreshing without mouse movement:

            Still, it somehow has to be related to the QGraphicsDropShadowEffect I apply to my topmost widget, since the bug appears and disappears depending on the blur radius. This is what puzzles me the most.

            Indeed this appears to be key to your finding. And would not be common for other users.

            It seems really "strange" that this would affect behaviour in the way your report. It might be "coincidence", somehow.

            I am not understanding what this "topmost widget" is. Your screenshots show a rectangular widget on which all your text and buttons are placed. Is that your "topmost widget"?

            If this genuinely depends just on some drop shadow effect, you really should be able to reproduce a tiny, standalone example. If not it makes me wonder about what else in your code might be the cause.

            PLL3P Offline
            PLL3P Offline
            PLL3
            wrote on last edited by
            #7

            @JonB Hi, thanks for the reply !

            Have a look at this diagram:
            34c43b0f-4629-44ca-80ae-ce08a677d63a-image.png

            This is a simplified (and anonymized) diagram of my app architecture. The "topmost widget" to which I apply the QGraphicsEffect is "shadowWidget". The "footer" is where the three buttons are. The "panelLayout" is where the actual content of the app would be loaded and "header" is, in effect, replacing the native windows taskbar (I removed it as well on the screen shots).

            I'll try one more time to reproduce my bug in QtCreator.

            JonBJ 1 Reply Last reply
            0
            • PLL3P PLL3

              @JonB Hi, thanks for the reply !

              Have a look at this diagram:
              34c43b0f-4629-44ca-80ae-ce08a677d63a-image.png

              This is a simplified (and anonymized) diagram of my app architecture. The "topmost widget" to which I apply the QGraphicsEffect is "shadowWidget". The "footer" is where the three buttons are. The "panelLayout" is where the actual content of the app would be loaded and "header" is, in effect, replacing the native windows taskbar (I removed it as well on the screen shots).

              I'll try one more time to reproduce my bug in QtCreator.

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

              @PLL3
              I respect what you say about your findings, but when looking at that diagram how would you guess anything on shadowWidget would get to affect something inside footer? Just saying.

              PLL3P 1 Reply Last reply
              0
              • JonBJ JonB

                @PLL3
                I respect what you say about your findings, but when looking at that diagram how would you guess anything on shadowWidget would get to affect something inside footer? Just saying.

                PLL3P Offline
                PLL3P Offline
                PLL3
                wrote on last edited by
                #9

                @JonB I'm not guessing, I'm just pointing out things I've noticed.

                Evidently there's something about QGraphicsDropShadowEffect that I don't get. I'm not even entirely sure if I'm using it correctly, maybe it's not made for the shadow effect on app windows but rather for visual purposes on some widgets, the doc isn't super useful here tbh.

                But from what I understood, correct me if I'm wrong, QGraphicsDropShadowEffect is supposed to propagate to children (or at least it does so in my tests), which prompts me to believe that I'm not supposed to use it for this but I don't know how else to do it.

                JoeCFDJ 1 Reply Last reply
                0
                • PLL3P PLL3

                  @JonB I'm not guessing, I'm just pointing out things I've noticed.

                  Evidently there's something about QGraphicsDropShadowEffect that I don't get. I'm not even entirely sure if I'm using it correctly, maybe it's not made for the shadow effect on app windows but rather for visual purposes on some widgets, the doc isn't super useful here tbh.

                  But from what I understood, correct me if I'm wrong, QGraphicsDropShadowEffect is supposed to propagate to children (or at least it does so in my tests), which prompts me to believe that I'm not supposed to use it for this but I don't know how else to do it.

                  JoeCFDJ Offline
                  JoeCFDJ Offline
                  JoeCFD
                  wrote on last edited by
                  #10

                  @PLL3 someone else had the same issue?
                  https://forum.qt.io/topic/121567/not-renewing-trying-to-set-qwebengineview-on-ui/3

                  PLL3P 1 Reply Last reply
                  0
                  • JoeCFDJ JoeCFD

                    @PLL3 someone else had the same issue?
                    https://forum.qt.io/topic/121567/not-renewing-trying-to-set-qwebengineview-on-ui/3

                    PLL3P Offline
                    PLL3P Offline
                    PLL3
                    wrote on last edited by
                    #11

                    @JoeCFD Thanks for the link. I've looked at it, it could indeed be the same issue, setBlurRadius() seems to also be the issue and we're both unsing Frameless windows.

                    But there doesn't seem to be a fi x proposed other than removing the call to setBlurradius() .

                    JoeCFDJ 1 Reply Last reply
                    0
                    • PLL3P PLL3

                      @JoeCFD Thanks for the link. I've looked at it, it could indeed be the same issue, setBlurRadius() seems to also be the issue and we're both unsing Frameless windows.

                      But there doesn't seem to be a fi x proposed other than removing the call to setBlurradius() .

                      JoeCFDJ Offline
                      JoeCFDJ Offline
                      JoeCFD
                      wrote on last edited by
                      #12

                      @PLL3 That could be a Qt bug. You can work around the issue by manually triggering a useless mouse event to update it after it is enabled since you know a mouse event can update it.

                      Or upgrade your Qt to see if the problem is fixed.

                      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