Summary: | Menu entries with submenu entries do not display keyboard shortcut | ||
---|---|---|---|
Product: | [Frameworks and Libraries] frameworks-kxmlgui | Reporter: | Tore Havn <veqz> |
Component: | general | Assignee: | kdelibs bugs <kdelibs-bugs> |
Status: | RESOLVED NOT A BUG | ||
Severity: | normal | CC: | kde |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Neon | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Attachments: | Kate showing its Input Modes menu entry, without a keyboard shortcut |
Does it have a shortcut assigned, even? Maybe it clashes with some other shortcut but I cannot reproduce with other actions such as Dolphin's submenus. You can assign shortcuts to menu items just fine, the "switch to next input mode" is a different action from the "input modes:" menu item and as such doesn't have a shortcut. |
Created attachment 120801 [details] Kate showing its Input Modes menu entry, without a keyboard shortcut I've noticed that the menu entries doesn't show their keyboard shortcuts if they have submenu entries. Attached is a screenshot of a menu entry in Kate that I've been looking at. The code for this entry is found in «kateview.cpp», lines 694-698: a = ac->addAction(QStringLiteral("switch_next_input_mode")); a->setText(i18n("Switch to Next Input Mode")); ac->setDefaultShortcut(a, QKeySequence(Qt::CTRL + Qt::SHIFT + Qt::Key_V)); a->setWhatsThis(i18n("Switch to the next input mode.")); connect(a, SIGNAL(triggered(bool)), SLOT(cycleInputMode()));