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

No menu bar on certain Linux environments

    XMLWordPrintable

Details

    Description

      Based on user reports for Slate, which uses the Qt Labs Platform MenuBar:

      Can also be verified with this snippet:

      import QtQuick 2.7
      import QtQuick.Controls 2.3
      
      import Qt.labs.platform 1.0 as Platform
      
      ApplicationWindow {
          id: window
          visible: true
          width: 640
          height: 480
      
          Platform.MenuBar {
              Platform.Menu {
                  title: "File"
      
                  Platform.MenuItem {
                      text: "New"
                  }
                  Platform.MenuItem {
                      text: "Save"
                  }
                  Platform.MenuItem {
                      text: "Open"
                  }
              }
          }
      }
      

      Since x11 doesn't have support for native menus, we need to get a QMenuBar fallback working. It looks like it's missing from here.

      https://doc.qt.io/qt-5.10/qml-qt-labs-platform-menubar.html#details:

      MenuBar is currently available on the following platforms:

      • macOS
      • Android
      • Linux (only available on desktop environments that provide a global D-Bus menu bar)

      Attachments

        Issue Links

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

          Activity

            People

              qt.team.quick.subscriptions Qt Quick and Widgets Team
              mitch_curtis Mitch Curtis
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes