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. QPushButton with stylesheet not working in 5.15.0
Forum Updated to NodeBB v4.3 + New Features

QPushButton with stylesheet not working in 5.15.0

Scheduled Pinned Locked Moved Solved General and Desktop
8 Posts 3 Posters 1.4k Views
  • 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.
  • G Offline
    G Offline
    glennr
    wrote on last edited by
    #1

    I have a complicated form based around a couple of QStackedWidgets. It has some stylesheets to add rounded corners and gradient backgrounds to the buttons. In 5.9.x it was working fine but in 5.15.0 the buttons inside the QStackedWidget do not respond to mouse clicks but the buttons outside of the QStackedWidget function as expected. Also if I remove the stylesheets the buttons work correctly. The issue is the same in my built app and in Designer. In Designer from 5.9 it works OK but in Designer from 5.15 it has the problem.

    I'm just wondering if anyone else has noticed similar behaviour or has a workaround?

    JonBJ 1 Reply Last reply
    1
    • G glennr

      I have a complicated form based around a couple of QStackedWidgets. It has some stylesheets to add rounded corners and gradient backgrounds to the buttons. In 5.9.x it was working fine but in 5.15.0 the buttons inside the QStackedWidget do not respond to mouse clicks but the buttons outside of the QStackedWidget function as expected. Also if I remove the stylesheets the buttons work correctly. The issue is the same in my built app and in Designer. In Designer from 5.9 it works OK but in Designer from 5.15 it has the problem.

      I'm just wondering if anyone else has noticed similar behaviour or has a workaround?

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

      @glennr
      This is purely a vague recollection from some post I think I saw recently: what platform are you? I thought I saw an issue like this if you are macOS...?

      1 Reply Last reply
      0
      • I Offline
        I Offline
        Imran Hassan
        wrote on last edited by
        #3

        I face same problem with QTabWidget. Outsied tab widget its working. I am using QT 5.14. If anyone has solution please share

        JonBJ 1 Reply Last reply
        0
        • I Imran Hassan

          I face same problem with QTabWidget. Outsied tab widget its working. I am using QT 5.14. If anyone has solution please share

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

          @Imran-Hassan
          Exactly the same question to you as to the OP: don't you think it's relevant to state what OS(es) this does or does not function on, if you are looking for help?

          G 1 Reply Last reply
          2
          • JonBJ JonB

            @Imran-Hassan
            Exactly the same question to you as to the OP: don't you think it's relevant to state what OS(es) this does or does not function on, if you are looking for help?

            G Offline
            G Offline
            glennr
            wrote on last edited by glennr
            #5

            @JonB Sorry, was focusing on the problem and forgot to mention the platform. Its on MacOS (10.15.5, Xcode 11.5). I'm in the middle of getting it set up on Windows so will report when I have that tested.

            JonBJ 1 Reply Last reply
            0
            • G glennr

              @JonB Sorry, was focusing on the problem and forgot to mention the platform. Its on MacOS (10.15.5, Xcode 11.5). I'm in the middle of getting it set up on Windows so will report when I have that tested.

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

              @glennr
              Then is your situation as reported in https://forum.qt.io/topic/116234/stylesheet-breaks-qpushbutton-pressed-on-macos ?

              G 1 Reply Last reply
              0
              • JonBJ JonB

                @glennr
                Then is your situation as reported in https://forum.qt.io/topic/116234/stylesheet-breaks-qpushbutton-pressed-on-macos ?

                G Offline
                G Offline
                glennr
                wrote on last edited by
                #7

                @JonB said in QPushButton with stylesheet not working in 5.15.0:

                @glennr
                Then is your situation as reported in https://forum.qt.io/topic/116234/stylesheet-breaks-qpushbutton-pressed-on-macos ?

                Yes, that is it.

                G 1 Reply Last reply
                0
                • G glennr

                  @JonB said in QPushButton with stylesheet not working in 5.15.0:

                  @glennr
                  Then is your situation as reported in https://forum.qt.io/topic/116234/stylesheet-breaks-qpushbutton-pressed-on-macos ?

                  Yes, that is it.

                  G Offline
                  G Offline
                  glennr
                  wrote on last edited by
                  #8

                  Found it in the bug tracker https://bugreports.qt.io/browse/QTBUG-84879 Looks like it will be fixed in 5.15.1.

                  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