Bug 169661 - [Feature request] LibreOffice - Add keyboard shortcut from right click menu of menu entry / UI button
Summary: [Feature request] LibreOffice - Add keyboard shortcut from right click menu o...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
25.8.3.2 release
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Customize-Dialog-Keyboard Context-Menu
  Show dependency treegraph
 
Reported: 2025-11-24 11:08 UTC by BDF
Modified: 2025-12-02 12:36 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
BLENDER - right click menu - add shortcut (62.24 KB, image/png)
2025-11-24 11:09 UTC, BDF
Details
CALC - feature request - keyboard shortcut - right click menu (1.49 MB, video/webm)
2025-11-25 09:22 UTC, BDF
Details

Note You need to log in before you can comment on or make changes to this bug.
Description BDF 2025-11-24 11:08:32 UTC
Description:
When you want to add a shortcut to a function inside a context menu or to a button, you have to open the window for keybindings and find the respective entry.
The suggestion is that every menu entry as well as UI button as an option in a right click menu to add a keyboard shortcut.

Steps to Reproduce:
1. Right click on entry of a context menu or a UI button

Actual Results:
There is no option displayed that allows you to quickly add a keyboard shortcut.

If you right click an entry in the context menu it acts as left click.
If you right click a UI button there is a menu, but there is no quick option to add a keyboard shortcut.

Expected Results:
There is a menu entry in the right click menu that either
a) allows you to set a keyboard shortcut right away (would be the better way IMO)
b) opens the already existing menu window for keyboard shortcuts and opens the function you want to add (probably the easier route as the keyboard shortcut window itself does already exist)


Reproducible: Always


User Profile Reset: No

Additional Info:
This functionality is not something new but a functionality that I have first seen in blender and was very handy over there (see screenshot).

LibreOffice info:
Version: 25.8.3.2 (X86_64) / LibreOffice Community
Build ID: 8ca8d55c161d602844f5428fa4b58097424e324e
CPU threads: 12; OS: Linux 6.14; UI render: default; VCL: gtk3
Locale: de-AT (de_AT.UTF-8); UI: de-DE
Flatpak
Calc: threaded
Comment 1 BDF 2025-11-24 11:09:36 UTC
Created attachment 204252 [details]
BLENDER - right click menu - add shortcut

The option to add a keyboard shortcut from a right click menu in blender
Comment 2 V Stuart Foote 2025-11-24 15:20:25 UTC
Interesting idea. Freely defined shortcuts/accelerators. 

This would require extending the accelerator/shortcut assignments now resident on the 'Customize...' dialog 'Keyboard' tab. Bringing an assignment function onto the context menu for Button control or Menu control objects.

IIANM all toolbar Button and menu Menu objects have UNO associated with the control object. And they report their accelerator/shortcut as assigned to the respective UNO (either from .UI, or by VCL). 

So in addition to rework of bug 115527, some simple context menu pop-up dialog for key entry with test/warning of prior use.

Also see some of the earlier comments on bug 88896 before the Customize dialog got a major rework for GSOC 2017 at the 6.0 release and comments on bug 115527

But, this all could be troublesome to implement. Locale driven keysym differences already have us struggling with issues like bug 115052 and without major refactoring have limitation to the keys published our API [1] and VCL implementation.

=-ref-=

[1] https://api.libreoffice.org/docs/idl/ref/namespacecom_1_1sun_1_1star_1_1awt_1_1Key.html
[2] https://opengrok.libreoffice.org/xref/core/include/vcl/keycodes.hxx
Comment 3 BDF 2025-11-25 09:22:07 UTC
Created attachment 204272 [details]
CALC - feature request - keyboard shortcut - right click menu

A video with a mockup on how version a) [=set a shortcut right away] could look like.

The video is meant for discussion not as concrete implementation.
Comment 4 V Stuart Foote 2025-11-25 11:08:47 UTC
(In reply to BDF from comment #3)
> Created attachment 204272 [details]

Yes, possibly something like that. And maybe also include/activate a button to launch the Customize dialog when there is a shortcut (or accelerator) conflict.
Comment 5 Heiko Tietze 2025-12-02 12:36:52 UTC
Like the idea. Matches nicely the suggestions around bug 115052 and bug 115527 comment 18.

I'm not a fan of right-clicking a menu. Could be alternatively a shortcut like F1 that opens the help with the hovered item as context. F2 could be intuitive as "rename".