symbols: Skip interprets only for groups with explicit actions #519
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Previously setting explicit actions for a group in symbols files made the parser skip compatibility interpretations for the corresponding whole key, so the other groups with no explicit actions could result broken on some levels.
In the following example,
<RALT>
would have an action on group 2, because it is explicit, but none on group 1 because interpretation are also skipped there as a side effect:Fixed by skipping interpretations only for groups with explicit actions.
We still set
key->explicit |= EXPLICIT_INTERP
if at least one group has explicit actions. In such case, when dumping a keymap, we will write explicit actions for all groups, in order to ensure that X11 and previous versions of libxkbcommon can parse the keymap as intended. One side effect is that no interpretation will be run on this key anymore, so we may have to set some extra fields explicitly: repeat, virtualMods. Thus the previous example would be bumped as:Fixes #511