Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Android QPushButton Style is not correct
Qt 6.11 is out! See what's new in the release blog

Android QPushButton Style is not correct

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
7 Posts 3 Posters 3.3k 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.
  • H Offline
    H Offline
    HappyLius
    wrote on last edited by
    #1

    For QT for Android 5.8, when I first started the compiled android software, the button's style is not correct, and when I quit the software and started again this app the style showed normal. i dont't know why
    0_1497236839550_Screenshot_2017-06-12-11-05-01-0958775448.png
    First open

    0_1497236806627_Screenshot_2017-06-12-11-05-22-0858757011.png
    open again

    1 Reply Last reply
    0
    • H Offline
      H Offline
      HappyLius
      wrote on last edited by
      #2

      0_1497237126893_)DZO@K[13]4ZEH}L_8Z{2ES.png

      the UI

      1 Reply Last reply
      0
      • H Offline
        H Offline
        HappyLius
        wrote on last edited by
        #3

        i need help.....

        J.HilkJ 1 Reply Last reply
        0
        • H HappyLius

          i need help.....

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

          @HappyLius
          if I remember correctly, that is the focus of the QPushbutton that is shown. That means, after the 2nd start, press the button and it should stay with the blue hue.

          I think I fixed that for me with removing the outline parameter from the stylesheet.

          Button->setStyleSheet(QPushButton{outline: none;});
          

          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.

          H 2 Replies Last reply
          1
          • J.HilkJ J.Hilk

            @HappyLius
            if I remember correctly, that is the focus of the QPushbutton that is shown. That means, after the 2nd start, press the button and it should stay with the blue hue.

            I think I fixed that for me with removing the outline parameter from the stylesheet.

            Button->setStyleSheet(QPushButton{outline: none;});
            
            H Offline
            H Offline
            HappyLius
            wrote on last edited by
            #5

            @J.Hilk i do as you said,it still show at wrong style
            think you.

            1 Reply Last reply
            0
            • J.HilkJ J.Hilk

              @HappyLius
              if I remember correctly, that is the focus of the QPushbutton that is shown. That means, after the 2nd start, press the button and it should stay with the blue hue.

              I think I fixed that for me with removing the outline parameter from the stylesheet.

              Button->setStyleSheet(QPushButton{outline: none;});
              
              H Offline
              H Offline
              HappyLius
              wrote on last edited by
              #6

              @J.Hilk said in Android QPushButton Style is not correct:

              start

              set the border of the button can solve the problem.
              setstyleSheet(border:none;border-radius:0px;)

              Not only the button ,but also many controls have this problem.
              such as QCheckBox. I dont't know how to solve this problem.

              1 Reply Last reply
              0
              • K Offline
                K Offline
                kuzulis
                Qt Champions 2020
                wrote on last edited by
                #7

                Yes, I'm too faced with this issue (e.g. this happens also when I try to deploy an application from QtC for debugging and so on). As I can say - this is fixed in Qt 5.9.0 (at least it is not reproducable anymore).

                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