Bug 94226 - Scroll Lock is not enabled by default
Summary: Scroll Lock is not enabled by default
Status: RESOLVED MOVED
Alias: None
Product: xorg
Classification: Unclassified
Component: Input/Keyboard (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium enhancement
Assignee: Xorg Project Team
QA Contact: Xorg Project Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-02-20 08:45 UTC by CJ Duncan
Modified: 2019-09-30 20:38 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description CJ Duncan 2016-02-20 08:45:03 UTC
For some reason, Scroll Lock is not enabled by default. I submit this bug as an enhancement, since as of this moment, I have no idea why Scroll Lock is not already enabled by default. That is the behavior that I expect.

My laptop keyboard does not have a key for Scroll Lock, so I did not notice anything was amiss. It is not until I purchased a keyboard with LED lighting that I noticed that when I pressed the Scroll Lock key, nothing was happening. I was expecting that if I pressed the Scroll Lock key, then the Scroll Lock indicator LED would turn on and the LED in my keyboard would turn on as well, but none of those actions happen. The LED indicator for Caps Lock and Num Lock worked fine, but not for Scroll Lock.

I noticed that if I go to one of the virtual terminals, by pressing Ctrl + Alt + F1 to F6, the Scroll Lock key worked as expected, and when I returned to the graphical interface it stopped working again. That indicated to me, that it probably has something to do with the Xserver. I went surfing online and I learned about xmodmap. I keyed the command xmodmap -pm and it gave the following output:

xmodmap:  up to 4 keys per modifier, (keycodes in parentheses):

shift       Shift_L (0x32),  Shift_R (0x3e)
lock        Caps_Lock (0x42)
control     Control_L (0x25),  Control_R (0x69)
mod1        Alt_L (0x40),  Meta_L (0xcd)
mod2        Num_Lock (0x4d)
mod3        
mod4        Super_L (0x85),  Super_R (0x86),  Super_L (0xce),  Hyper_L (0xcf)
mod5        ISO_Level3_Shift (0x5c),  Mode_switch (0xcb)

By commanding xmodmap -e "add mod3 = Scroll_Lock" it changed the xmodmap -pm output to:

xmodmap:  up to 4 keys per modifier, (keycodes in parentheses):

shift       Shift_L (0x32),  Shift_R (0x3e)
lock        Caps_Lock (0x42)
control     Control_L (0x25),  Control_R (0x69)
mod1        Alt_L (0x40),  Meta_L (0xcd)
mod2        Num_Lock (0x4d)
mod3        Scroll_Lock (0x4e)
mod4        Super_L (0x85),  Super_R (0x86),  Super_L (0xce),  Hyper_L (0xcf)
mod5        ISO_Level3_Shift (0x5c),  Mode_switch (0xcb)

Now the Scroll Lock works, but this change is temporary. Once the computer restarts, the settings reset. I went surfing a little more and I learned about how to make the change more permanent. I found an XKB configuration file located at /usr/share/X11/xkb/symbols/us and modify it by adding modifier_map Mod3 { Scroll_Lock }; in xkb_symbols "basic" After that, I did a reset to the XKB layout cache by executing sudo rm -f /var/lib/xkb/* and sudo rm -f /var/lib/lib/xkb/*

I restarted the computer, and now every time I use the keyboard, no matter how many times I restart the computer, the Scroll Lock key works.

I do not think that this should be the case. I was expecting the Scroll Lock key to work out-of-the-box. Can we change this so that it does work out of the box?
Comment 1 CJ Duncan 2016-04-03 23:47:26 UTC
I am still available for any questions, if need be.
Comment 2 CJ Duncan 2016-04-28 15:10:18 UTC
Just upgraded to Ubuntu 16.04 LTS, and the problem still persists.
Comment 3 David Sutton 2016-08-20 00:18:25 UTC
Thanks CJ Duncan for the bug report, including the patching instructions which worked for me. The average user should not need to struggle with this. Scroll_Lock should "just work".
Comment 4 GitLab Migration User 2018-08-10 20:55:55 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/xorg/driver/xf86-input-keyboard/issues/20.
Comment 5 Ali 2019-09-30 19:17:56 UTC
Hi. I didnt understand exactly what should ı do to fix this bug. I just started to linux. Pls help me :)
Comment 6 Andre Klapper 2019-09-30 20:38:07 UTC
(In reply to Ali from comment #5)
> Hi. I didnt understand exactly what should ı do to fix this bug. I just
> started to linux. Pls help me :)

Ali: As with any software bug, if you want to fix this bug yourself, you have to investigate the reason by looking at the public code base, try to reproduce, compile, and test if your code changes fix the bug.

If you only want to follow this bug report, then you can do so at
https://gitlab.freedesktop.org/xorg/driver/xf86-input-keyboard/issues/20
as bugs.freedesktop.org is getting closed.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.