Bug 418307 - Additional keyboard shortcuts for Klipper navigation (Vim-like)
Summary: Additional keyboard shortcuts for Klipper navigation (Vim-like)
Status: REOPENED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Clipboard widget & pop-up (show other bugs)
Version: 5.15.3
Platform: Arch Linux Linux
: NOR normal
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-02-28 23:48 UTC by G360
Modified: 2023-08-11 13:26 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description G360 2020-02-28 23:48:25 UTC
SUMMARY
The Klipper window can be navigated using the Up and Down keyboard arrows, but lacks other popular options, like Vim-like shortcuts (Ctrl-j and Ctrl-k, also modal modes) or Emacs-style shortcuts (Ctrl-p and Ctrl-n).

STEPS TO REPRODUCE
1. Open the Klipper Plasma tray icon or the "Open Klipper at Mouse Position" window.
2. Try to navigate using the keyboard with anything other than the arrows.
3. Press Ctrl-p, Ctrl-n, Ctrl-j, or Ctrl-k.

OBSERVED RESULT
Nothing.

EXPECTED RESULT
Previews/next clipboard item should be selected.

SOFTWARE/OS VERSIONS
KDE Plasma Version: 5.18.2
KDE Frameworks Version: 5.67.0
Qt Version: 5.14.1
Comment 1 David Edmundson 2020-02-29 00:01:14 UTC
Adding support in just klipper doesn't make a lot of sense.

You may find systemsettings -> standard shortcuts will cover your needs
Comment 2 G360 2020-03-02 14:10:12 UTC
Thanks @David. 

I did set the Standard Shortcuts for "Next Item in List" —which has primary shortcut set as "Down"— on the Alternative option to Ctrl+j, but unfortunately this behaves as having no effect.  The same with "Previews Item in List".  

This does not only happen on Klipper but is also reproducible on other programs like Gweenview, Up/Down keys work, but not Ctrl-j/k.
Comment 3 Noah Davis 2023-08-11 13:26:20 UTC
The shortcut customization doesn't work because plasma-workspace/applets/clipboard/contents/ui/ClipboardPage.qml doesn't try to use KStandardShortcuts. The reason why is that KStandardShortcuts is not available for QML. We should either try to make upstream equivalent shortcuts for QKeySequence::StandardKey so that our platform theme can set them appropriately or make KStandardShortcuts available to QML directly.