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

Raise the layout limit to 32 #515

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

wismill
Copy link
Member

@wismill wismill commented Sep 27, 2024

With #362 merged, Time Has Come!

32 is probably too much, but unless we are wasting memory somewhere, I see no reason to not allow the maximum.

Fixes #37

TODO:

  • Add more tests (all components, states, X11, etc.)
  • Publish working rules in xkeyboard-config
  • Log entry

@wismill wismill added compile-keymap Indicates a need for improvements or additions to keymap compilation X11 legacy: limitations Indicates a need to lift legacy X11 limitations state Indicates a need for improvements or additions to the xkb_state API rules labels Sep 27, 2024
@wismill wismill added this to the 1.9.0 milestone Sep 30, 2024
@zzag
Copy link

zzag commented Oct 22, 2024

On the desktop environment side, would we need to do something? or things will "just work" after updating xkbcommon and xkeyboard-config?

@wismill
Copy link
Member Author

wismill commented Oct 23, 2024

@zzag For now we do not expose the max number of layouts, so this limit is probably set using X11's XkbNumKbdGroups or simply hard-coded. We should provide our own upper bound.

If a DE supports both Wayland and X11, the tricky part is how to interface with XWayland. Indeed, under a pure X11 or Wayland session, it suffices to use the respective limits.

First solutions that come to my mind:

  • Change nothing 😄
  • Use a 4 moving subset of the layouts, which should include the first one1 and the current one, with some buffer. E.g. for layouts a,b,c,d,e,f, if e is active then compile the keymap with layouts a,d,e,f for XWayland.

By the way, what DE do you deal with?

Footnotes

  1. The first layout is the default layout and may have an impact on the overall keymap.

@zzag
Copy link

zzag commented Oct 23, 2024

By the way, what DE do you deal with?

Plasma

@wismill
Copy link
Member Author

wismill commented Oct 23, 2024

By the way, what DE do you deal with?

Plasma

@zzag I opened a KWin issue a few weeks ago.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compile-keymap Indicates a need for improvements or additions to keymap compilation rules state Indicates a need for improvements or additions to the xkb_state API X11 legacy: limitations Indicates a need to lift legacy X11 limitations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove the 4 layout limit on Wayland.
2 participants