Bug 49091 - UI: Alt-Left, Alt-Right keyboard shortcuts ineffective
Summary: UI: Alt-Left, Alt-Right keyboard shortcuts ineffective
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
(earliest affected)
Inherited From OOo
Hardware: Other All
: medium minor
Assignee: Not Assigned
Whiteboard: target:7.4.0
Keywords: needsDevEval, topicDebug, topicUI
: 53190 93402 (view as bug list)
Depends on:
Blocks: Customize-Dialog-Keyboard Shortcuts-Accelerators
  Show dependency treegraph
Reported: 2012-04-23 15:43 UTC by ryan.jendoubi@gmail.com
Modified: 2022-06-13 10:26 UTC (History)
9 users (show)

See Also:
Crash report or crash signature:


Note You need to log in before you can comment on or make changes to this bug.
Description ryan.jendoubi@gmail.com 2012-04-23 15:43:13 UTC
Just spent 20 minutes getting very confused as to why I couldn't assign the Navigation controls "Back" and "Forward" to a keyboard shortcut. Had a nice long bug report all typed up for it, but before posting tried different shortcuts...

Sure enough, I could assign them to Alt-B and Alt-F, but not Alt-Left and Alt-Right :p

A little more experimenting and it seems that no matter what one assigns to these combinations, all that happens is the cursor moves left and right completely normally: their shortcut function isn't activated at all.

I haven't upgraded to the 5.x series yet for a number of reasons (including Bug 47764 and Bug 46155) so I'd appreciate if someone else could check that this bug still exists in the newest versions :-)

Steps to reproduce: In LibreOffice Writer:
1. Go to the Tools menu > Customize...
2. If not selected, select the Keyboard tab
3. Assign some (any) function to the Alt-Left and Alt-Right key combinations
4. Return to your document
5. Test the Alt-Left and Alt-Right keyboard shortcuts
*Result: No effect: shortcut functions not activated*
Comment 1 Rainer Bielefeld Retired 2012-04-24 01:52:35 UTC
[Reproducible] with "LibreOffice (RC1) German UI/Locale [Build-ID: 21cb047-d7e6025-9ba54fc-b4a51a8-f42372b] on German WIN7 Home Premium (64bit). I tried to associate a  macro to <Alt+leftarrow>, failed. macro is shown in list of shortcuts, but it will not be executed.

It's different in Calc, there <Alt+leftarrow> and <Alt+rightarrow> are used, but I can customize, I tried to associate a macro to <Alt+leftarrow>, worked fine.
Comment 2 Joel Madero 2014-02-27 23:28:30 UTC Comment hidden (obsolete)
Comment 3 Rachit Gupta 2014-04-10 04:54:17 UTC
I'm working on this bug. Seems like Alt+<any_arrow_key> does not work.
Comment 4 Regina Henschel 2014-04-14 17:39:14 UTC
It depends on the context.
If a graphic object or a presentation object is selected, then Alt+Arrow is used for one pixel movement of the object or in point mode for movement of a single point.
If the cursor is inside a Writer table, Alt+LeftArrow and Alt+RightArrow is used to manipulate the column width, Alt+UpArrow and Alt+DownArrow for row height. In addition there are some bindings for languages with composed character.
In accessibility context Alt+DownArrow and Alt+UpArrow is used to open/close a drop-down-list in a dialog or a combox-box in forms.
In Calc Alt+DownArrow and Alt+UpArrow depends on the chosen key bindings in Tools>Options>Calc>Compatibility.

So it is not true that "Alt+<any_arrow_key> does not work". So when you alter something please make sure, that the existing bindings still work.
Comment 5 Rachit Gupta 2014-04-15 15:08:04 UTC
Actually what I meant was that when we assign a new binding to Alt+<any_arrow_key>, the assigned bindings do not work. So more than 1 bindings can be assigned to Alt+<any_arrow_key> ? And when the key combination is pressed, then all the actions are to be performed?
Comment 6 Rachit Gupta 2014-04-18 05:34:45 UTC
Or, maybe if Alt+<arrow_keys> already have predefined assignments, maybe we could remove these key bindings from being customized by the user?
Comment 7 Kohei Yoshida 2014-04-23 13:16:39 UTC
Just FYI, the expected action is that, if a user assigns a custom action, that one should take precedence.  If no action is mapped, whatever writer does by default should be triggered.  Calc does it that way too.  I'm surprised Writer didn't follow this behavior.
Comment 8 Kohei Yoshida 2014-04-23 13:24:29 UTC
But I do see some element of complexity in handling this, as Regina outlined in Comment 4.
Comment 9 Rachit Gupta 2014-04-25 10:49:23 UTC

I won't be able to work on this bug any more. Someone else can take it. I'll share some of my findings:

The code for the key combinations in Writer is held in sw/source/core/uibase/docvw/edtwin.cxx, search for the while loop in the KeyInput method. The variable eKeyState does not get set to KS_KeyToView, which results in the key combinations being ineffective.

Rachit Gupta
Comment 10 V Stuart Foote 2015-08-17 01:28:39 UTC
*** Bug 93402 has been marked as a duplicate of this bug. ***
Comment 11 tommy27 2015-10-17 08:39:53 UTC
just to tell that OOo 3.3.0 had the same problem with those "Alt+Left" and "Alt-Right" keyboard shortcuts

problem persists in LibO alpha too
Comment 12 Robinson Tryon (qubit) 2015-12-13 10:25:39 UTC Comment hidden (obsolete)
Comment 13 Björn Michaelsen 2016-01-26 18:02:37 UTC Comment hidden (obsolete)
Comment 14 Björn Michaelsen 2016-01-26 18:04:57 UTC Comment hidden (obsolete)
Comment 15 Buovjaga 2016-03-09 08:35:28 UTC
*** Bug 53190 has been marked as a duplicate of this bug. ***
Comment 16 Björn Michaelsen 2016-03-29 22:58:16 UTC
55838 and 49091 are possibly related
Comment 17 QA Administrators 2017-05-22 13:20:29 UTC Comment hidden (obsolete)
Comment 18 QA Administrators 2019-12-03 14:02:30 UTC Comment hidden (obsolete)
Comment 19 Janvi 2020-03-12 16:09:58 UTC
confirm this bug for  LibO
Build-ID: 1:6.0.7-0ubuntu0.18.04.10
For Alt - left the ALT key is ignored doing same than without ALT
Comment 20 Vince 2022-04-06 23:18:39 UTC
As one who reported this bug a long time ago to https://bz.apache.org/ooo/show_bug.cgi?id=113502 and later as duplicate bug 53190, I have have been resigned to live without the ability of customizing Alt+(Right,Left) in Writer.

I finally decided to tackle this as well as another keyboard customization bug and will be submitting a patch to gerrit soon.

The ability to interactively resize writer tables using the keyboard has been around for a long time. This capability is described in the help: https://help.libreoffice.org/6.2/en-US/text/swriter/guide/table_sizing.html

The way this capability has been implemented breaks the ability for users to customize table sizing keystrokes to do other things. My patch corrects that by giving priority to keyboard customization if it exists.

The keyboard table resizing functionality is pretty nice and I thought there might be a case where even if a user wants to customize the table sizing keystrokes to do other things, they still might want have access to that functionality when needed. My patch provides for that as follows: When Caps Lock is turned on, customized table sizing keystrokes are ignored and instead will produce their default table sizing actions. Turning Caps Lock off restores custom action.

Finally it should be noted even if Alt+Right or Alt+Left have NOT been customized and you are NOT in a table, they behave like Right and Left respectively instead of acting like dead keys. My patch does not address this idiosyncrasy.
Comment 21 Commit Notification 2022-04-07 12:57:58 UTC
Vincent Reher committed a patch related to this issue.
It has been pushed to "master":


Resolve tdf#49091 "UI: Alt-Left, Alt-Right keyboard shortcuts ineffective"

It will be available in 7.4.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:

Affected users are encouraged to test the fix and report feedback.
Comment 22 Timur 2022-05-10 10:26:30 UTC
This seems resolved. 
Vincent, thanks, when you do it, also close as Fixed. I do it now.