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

Custom style names not added to file selectors

    XMLWordPrintable

Details

    • fdd62a5b81 (qt/qtdeclarative/dev) fdd62a5b81 (qt/tqtc-qtdeclarative/dev) c5e049c7d3 (qt/qtdeclarative/6.3) c5e049c7d3 (qt/tqtc-qtdeclarative/6.3) c5e049c7d3 (qt/tqtc-qtdeclarative/6.3.1)

    Description

      There seems to be a limitation with custom Controls styles. Following this:

      https://doc.qt.io/qt-6/qtquickcontrols2-customize.html#definition-of-a-style

      A user might want to make a custom component (not part of the custom style) and a version of it for each of the styles relying on file selectors. For example, MyItem component could be created with following files:

      MyItem.qml
      +Fusion/MyItem.qml
      +macOS/MyItem.qml
      

      This should work perfectly fine with compile-time styling option using built-in styles. The style name is added to file selector so the correct style gets picked up.

      However, if the user has created a custom style called MyCustomStyle, which itself works fine, but then tries to add special case also for MyItem:

      +MyCustomStyle/MyItem.qml
      

      But unfortunately nothing is adding MyCustomStyle into the file selectors, and instead there is only the underlying fallback style added to the file selectors, so only the version for the fallback style is loaded.

      Attachments

        1. qtbug99117.zip
          3 kB
          Joni Poikelin
        2. qtbug99117-menubaritem.zip
          14 kB
          Mitch Curtis
        3. qtbug99117-menubaritem-compile-time-without-patch.png
          19 kB
          Mitch Curtis
        4. qtbug99117-menubaritem-compile-time-with-patch.png
          19 kB
          Mitch Curtis
        5. qtbug99117-menubaritem-run-time-without-patch.png
          20 kB
          Mitch Curtis
        6. qtbug99117-menubaritem-run-time-with-patch.png
          20 kB
          Mitch Curtis

        Issue Links

          Activity

            People

              mitch_curtis Mitch Curtis
              poikelin Joni Poikelin
              Votes:
              1 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: