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

No control over the platform theme

    XMLWordPrintable

Details

    • Bug
    • Resolution: Incomplete
    • P3: Somewhat important
    • None
    • 5.1.0
    • GUI: Look'n'Feel
    • None

    Description

      Users of Qt applications can choose the platform plugin and the application style using either command line arguments or environment variables:

      $ ./app -platform xcb -style fusion
      $ QT_QPA_PLATFORM=xcb QT_STYLE_OVERRIDE=fusion ./app
      

      However, there's no way to control the platform theme that provides natives dialogs and so on. Ideally there should be no need for that, but platforms may provide several themes (like on XCB we have KDE, GTK & generic) and the desktop environment detection routines in Qt are not perfect since they rely on XDG_CURRENT_DESKTOP/DESKTOP_SESSION environment variables that might or might not be correctly set. Therefore there should be a way to control the platform theme. Here are some ideas:

      Perhaps we could combine it to the existing platform parameter and environment variables:

      $ ./app -platform xcb:gtk
      $ QT_QPA_PLATFORM=xcb:gtk ./app
      

      Or just provide new ones:

      $ ./app -platform xcb -platformtheme gtk
      $ QT_QPA_PLATFORM=xcb QT_QPA_PLATFORMTHEME=gtk ./app
      

      Attachments

        For Gerrit Dashboard: QTBUG-30091
        # Subject Branch Project Status CR V

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            jpnurmi J-P Nurmi
            Votes:
            1 Vote for this issue
            Watchers:
            10 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes