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

Win+Space shortcut for keyboard layout switching not working with some layouts #711

Closed
wxl opened this issue Jan 22, 2021 · 6 comments
Closed

Comments

@wxl
Copy link
Member

wxl commented Jan 22, 2021

The Win+Space short cut works, but only moving to certain keyboard layouts, not from them. This is not a problem with many other shortcuts, including all the other Win options. It only affects certain layouts. So far I have tested Persian (where it was originally reported) but also Afghani.

Expected Behavior

Win+Space always switches keyboard layout.

Current Behavior

Switching out of Persian or Afghani with Win+Space does not work. You can switch to it, but not out of it. That means if English is default and Persian is second, it works to switch to Persian, but does not work to switch back. On the other hand, if Persian is default and English second, you can't switch at all.

Steps to Reproduce (for bugs)

NOTE: this assumes a normal English keyboard.

  1. Open up keyboard layout settings
  2. Set English as default and Persian as second
  3. Set Win+Space as the shortcut
  4. Click apply
  5. Open Featherpad
  6. Type test
  7. "test" is printed
  8. Hold Meta while hitting Space
  9. Type test
  10. "فثسف" is printed
  11. Hold Meta while hitting Space
  12. Type test
  13. "فثسف" is printed where "test" should be
  14. Open up keyboard layout settings
  15. Swap the position of English and Persian so Persian is default
  16. Click apply
  17. Open Featherpad
  18. Type test
  19. "فثسف" is printed
  20. Hold Meta while hitting Space
  21. Type test
  22. "فثسف" is printed where "test" should be
Other information

Just to remove any possibility of conflicts, I disabled all Meta/Super shortcuts in Global Keys and also ensured there were no Meta/Super shortcuts in the window manager configuration (Lubuntu doesn't have any by default in Openbox).

I also checked with both French and Belgian and had no problems switching around as much as I liked, so it does not affect all layouts.

FWIW, downstream bug is here.

And another thing…

Why do we call it Win?! We really should use Meta/Super as Global Keys does.

System Information
  • Distribution & Version: Lubuntu 20.10
  • Kernel: 5.8.0
  • Qt Version: 5.15.2
  • liblxqt Version: 0.16.0
  • Package version: 0.15.0+git202101221151~hirsute-0ubuntu1~ppa1
    • NOTE: this is upstream Git master as of 11:51am today merged with our current version which is, yes, 0.15.0. What that means, though, is that this is really 0.16.0 and then some.
@tsujan
Copy link
Member

tsujan commented Jan 22, 2021

Questions:

  1. Only Meta+Space?
  2. With or without localization?

Will check it tomorrow.

@wxl
Copy link
Member Author

wxl commented Jan 22, 2021

1. Only `Meta+Space`?

I did not exhaustively check every single shortcut option, but I checked all the Meta ones as well as a few extra ones (like Shift). The only one I could really get to misbehave was that one.

2. With or without localization?

Not sure about the OP who's Iranian so I imagine they probably had something, but for my test, I did nothing to change or add to the localization from the default en_US.UTF-8.

@tsujan
Copy link
Member

tsujan commented Jan 23, 2021

I was able to reproduce the problem but I found nothing in our code that could explain it.

However, I could reproduce exactly the same problem under KDE. So, most probably, it's an upstream bug. But where?

To narrow down the probable causes, I checked gnome-shell: It had no problem with Meta+Space + English + Persian. Therefore, I think the issue should be somewhere in Qt itself.

As far as I know, Meta+Space does nothing in Persian (Shift+Space inserts the non-breaking space, ZWNJ, which is needed by Persian and, maybe, Hebrew).

@cas1no
Copy link

cas1no commented Dec 12, 2021

I found the same issue but with the EN, RU, PL configuration. The sequence of the languages should be precisely like this, e.g. EN, PL, RU or just EN, PL works just fine, but with EN, RU, PL I cannot switch back to EN from PL 😕

@wxl
Copy link
Member Author

wxl commented Apr 2, 2024

This is reproducible in 0.17.1 but not in versions ≥ 1.3.0, so it got fixed somewhere, whether in lxqt-config or not.

To be clear, I only tested the steps I originally posted, so I didn't check other shortcut options or other keyboard layouts.

@wxl wxl closed this as completed Apr 2, 2024
@tsujan
Copy link
Member

tsujan commented Apr 2, 2024

It reminds me of https://bugreports.qt.io/browse/QTBUG-62102, although it's about QKeySequenceEdit and fixed in Qt 6.6.

EDIT: Contrary to its title, it wasn't limited to Wayland but happened under X11 too.

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

No branches or pull requests

3 participants