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

Shortcuts requiring but not specifying Shift fail on Mac

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Fixed
    • Affects Version/s: 5.7.1
    • Fix Version/s: 5.8.0 RC
    • Component/s: QPA
    • Labels:
      None
    • Environment:
      Mac OS X 10.9.5 on a 2011 13" MBP with a wired compact US English Apple Keyboard, by default using the Canadian English keymap.
    • Platform/s:
      macOS

      Description

      QAction shortcuts of the type Command+! or Command+< (US/Canadian English keymap) or Command+1 (French keymap) that require the Shift modifier but don't specify it explicitly always worked reliably. Qt 5.7.1 introduced a regression for me which causes these shortcuts to fail when the QAction is not attached to a menu in the native menubar.

      The workaround versions spelling out the shortcut in keymap-specific keystrokes still work (resp. Command+Shift+1 Command+Shift+ Command+Shift+&).

      I have adapted the "menus" example to serve as a demonstrator; it adds a "shortcut test action" to the menubar and/or the context menu:
      https://github.com/RJVB/shortcut-test-qt5
      By default the action has the Command+< shortcut and is added to the menubar in native mode plus to the context menu. In this configuration the shortcut works for me
      Launching the app with either `-no-native-menubar` (use an in-window menubar) and/or with `-no-shortcut-test-in-menubar` (don't add the test action to the menubar) renders the shortcut inoperable for me.
      The shortcut can be selected via the `--shortcut` option.

      See also bug #57990 .

        Attachments

          Issue Links

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

            Activity

              People

              Assignee:
              qt.team.graphics.and.multimedia Qt Graphics Team
              Reporter:
              rjvbertin René Bertin
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes