Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-115036

Windows 10 Dark Mode: Disabled QPushButton labels are not grayed out

    XMLWordPrintable

Details

    • Windows

    Description

      It is widely documented that the default `windowsvista` style doesn't properly support Dark Mode. However, Dark Mode nevertheless causes labels on disabled `QPushButton`s to be rendered as black, making them hard to distinguish from enabled ones. The only other older Qt version I still have installed, 5.15.2, did not have this issue.

      This can be reproduced with the TextFinder example project. After unchecking `enabled` for the `findButton` in `textfinder.ui`:

      Switching to Light Mode (either between a restart of the program or even while it is running) fixes the button label color:

      As does applying the Fusion style via `QApplication::setStyle("fusion");`, which gives the same result in both Light and Dark Mode:

      Attachments

        1. windows_light-1.png
          windows_light-1.png
          46 kB
        2. windows_light.png
          windows_light.png
          46 kB
        3. windows_dark-1.png
          windows_dark-1.png
          41 kB
        4. windows_dark.png
          windows_dark.png
          41 kB
        5. image-2023-07-03-21-04-13-925.png
          image-2023-07-03-21-04-13-925.png
          8 kB
        6. image-2023-07-03-21-03-09-433.png
          image-2023-07-03-21-03-09-433.png
          6 kB
        7. image-2023-07-03-21-02-55-573.png
          image-2023-07-03-21-02-55-573.png
          6 kB

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              tpochep Timur Pocheptsov
              claudiohoffmann Nameless Legacy
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes