Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ScrollLock is enabling and disabling automatically #321

Closed
Neurotoxin001 opened this issue Jan 26, 2020 · 11 comments
Closed

ScrollLock is enabling and disabling automatically #321

Neurotoxin001 opened this issue Jan 26, 2020 · 11 comments

Comments

@Neurotoxin001
Copy link

Neurotoxin001 commented Jan 26, 2020

v0.9.4
Keyboard Leopold FC750R PD

With WinCompose launched I have ScrollLock glitches, once I press on it — it's turns on and off automatically, and when I press CapsLock — ScrollLock is enabling too. To reset it I must unplug my keyboard or just restart WinCompose and don't touch ScrollLock.

Settings:
image
image
image

This happens even when "Keyboard LED" is "Disabled"

@Neurotoxin001
Copy link
Author

Bump, it's annoying

@Neurotoxin001
Copy link
Author

When I press "pause break" scroll lock is disabling, but wtf? There is nothing about scroll lock in settings, and scroll lock enabling whatever option in "Keyboard LED" chosen

@samhocevar
Copy link
Owner

Sorry for not following-up on this… it’s pretty puzzling, as WinCompose doesn’t treat those keys in a particular way.

Could you please do the following:

  • open the debug window (using the notification icon menu)
  • do anything to reproduce the problem, but make sure you press Scroll Lock and Pause Break at least once
  • make a screenshot of the debug window and post it here

This may help me get some clues. Thanks!

@Neurotoxin001
Copy link
Author

Neurotoxin001 commented Apr 2, 2020

image

Sometimes to enable or disable scroll lock I must press it 2 times btw (without wincompose I must do it only one time).

When scroll lock automatically disabling/enabling there is no reports of it in debug window. Only when I press/release the button.

So there is 2 states:

  1. When I connect my keyboard first time — scroll lock is automatically enabling once I enable it manually
  2. BUT when I press "Pause break" — scroll lock will automatically disable after ~3-5 seconds and will always automatically disable even if I enable it manually. To enable scroll lock I must press "pause break" again, but it's will be "always" enable mode, because in this state I can't disable it without pressing "pause break" again.

@Neurotoxin001
Copy link
Author

0.9.10 not fixed

@sigprof
Copy link

sigprof commented Aug 10, 2021

Yes, the problem is present in 0.9.10. The debug window just shows keypresses of Pause and Scroll Lock, and does not show any new messages when the Scroll Lock indicator state actually changes:

image

The behavior seems as if WinCompose is internally maintaining its own Scroll Lock indicator state, and periodically updates the system state of the Scroll Lock indicator to match that internal state, but that internal state is actually toggled when the Pause key is pressed.

I found this commit: f407a12 — for some reason it has this:

    private static readonly IDictionary<VK, KEYBOARD> m_vk_to_flag = new Dictionary<VK, KEYBOARD>()
    {
        { VK.CAPITAL, KEYBOARD.CAPS_LOCK_ON },
        { VK.NUMLOCK, KEYBOARD.NUM_LOCK_ON },
        { VK.PAUSE,   KEYBOARD.SCROLL_LOCK_ON },
    };

Why VK.PAUSE is used instead of VK.SCROLL here (and then also in ValidLedKeys in the subsequent code)? The code before that commit was using VK.SCROLL; the commit message and the referenced issue do not provide any explanation for this mismatch.

@samhocevar
Copy link
Owner

Thanks @sigprof , that old code is the probable cause. My keyboard does not have a Scroll Lock key so I never noticed the bug.

@samhocevar
Copy link
Owner

Hi! And thank you for being patient. I believe this issue may be fixed in WinCompose 0.9.11. Could you please test the new version?

@Neurotoxin001
Copy link
Author

Seems like fixed now

@notwa
Copy link

notwa commented Sep 4, 2021

ah! this affected my current keyboard and my previous as well. I hadn't suspected that WinCompose was the culprit. after having experimented with 0.9.10 and 0.9.11, this issue appears to be fixed.

@samhocevar
Copy link
Owner

Thanks again, and sorry for the inconvenience! I'll be closing this issue now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants