SUMMARY This code is problematic: Shortcut { //in case of explicit & the button manages it by itself enabled: !(RegExp(/\&[^\&]/).test(controlRoot.text)) It does not handle even what it's directly supposed to: an ampersand but not a double ampersand. This snippet is duplicated across several controls. It should be fixed by rewriting into native (C++) code. STEPS TO REPRODUCE 1. console.log(!(RegExp(/\&[^\&]/).test("Yaha && ha!"))) OBSERVED RESULT false EXPECTED RESULT true ADDITIONAL INFORMATION Affected components are: - Button.qml - CheckBox.qml - MenuBarItem.qml - MenuItem.qml - RadioButton.qml - Switch.qml - TabButton.qml - ToolButton.qml
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/qqc2-desktop-style/-/merge_requests/241