Age | Commit message (Collapse) | Author | Files | Lines |
|
Layout compatibility rules are broken in configurations with 2 or more
layouts, e.g.:
- Works:
- config: `--layout fi --variant basic`
- symbols: `pc+fi(classic)+inet(evdev)`.
`fi(basic)` is correctly remapped to `fi(classic)`.
- Does not work:
- config `--layout fi,us --variant basic,`
- symbols: `pc+fi(basic)+us:2+inet(evdev)`.
`fi(basic)` is not remapped and leads to an include error.
- Does not work:
- config `--layout us,fi --variant ,basic`
- symbols: `pc+us:fi(basic):2+fi(classic):2+inet(evdev)`.
`fi(basic)` is not remapped and leads to an include error.
I initially thought merging the following rules sets to fix it:
1. `model layout[n] = symbols`
2. `model layout[n] variant[n] = symbols`
but it does not work: `*` wildcard does *not* match empty values.
There is another issue: using a variant will check and match *both*
rules sets. In the first rule set, compat rules are only for deleted
symbols files (e.g. `dev`). But when the symbols file exists, we end
up with an invalid include statement (see `fi(basic)` examples above).
This is because the first rules set has a catch-all rule that will
always match, while we want it to match only in the second rules set.
Unfortunately such rules cannot be expressed in rules files. So the
solution is to append generated compatibility sections in the
corresponding symbols files and remove the corresponding current rules.
Section name clashes are checked and will raise an error.
E.g.: currently we append the following to `symbols/de`:
partial xkb_symbols "lld" {
include "it(lldde)"
};
If we already had a section named lld, this would produce the following
error:
Cannot add compatibility section in symbols/de: "lld" already exists
Also:
- Move symbols handling in meson into the symbols subfolder.
- Sort compat layout rules.
- We ensure that rules with variant take priority over rules without one.
Part-of: <https://gitlab.freedesktop.org/xkeyboard-config/xkeyboard-config/-/merge_requests/728>
|
|
Previously the compatibility rules where incorrect:
- Lines with a comment starting by “//” where parsed incorrectly,
because comments where in fact not supported.
- `variantsMapping.lst` was added to rules without variant.
This resulted in incorrect rules with MLVO = (model, layout), e.g. the
beautiful following rules:
```
! model layout = symbols
* mao(nz(mao)) = pc+//(Delete)
* ben(basic) = pc+in(ben)
```
Fixed the issue and ensure to raise an error if expectation on layout
variant is broken.
|
|
Fallback with package `strenum` is required for Python < 3.11.
Part-of: <https://gitlab.freedesktop.org/xkeyboard-config/xkeyboard-config/-/merge_requests/702>
|
|
|
|
|
|
The vast majority of options are a straightforward foo:bar = +foo(bar)
mapping. Instead of maintaining those mappings by hand let's generate
the rules file from the files we definitely maintain by hand: the
base.xml (and base.extras.xml) files.
This also makes it clearer which ones are exceptions and need to be
filled in through other means (or ignored because the option does not
affect any symbols).
The resulting rules file is identical to the previous hand-generated
one but it is alphabetically sorted and uses different whitespacing.
For merge.py to work we need to also fix the whitespaces in
rules/compat/0041-option_symbols.part, otherwise the duplicate header
detection won't work.
|
|
This makes it immediately readable what maps to what over e.g.
ml4_s.part.
|
|
use the builtin `install_symlink` target provided by meson instead of providing on external `ln` and `sh`.
|
|
In general, options whose name ends in "_switch" do something *while*
the relevant key or key combination is being held -- see, for example,
grp:menu_switch, lv3:ralt_switch, or lv5:rctrl_switch.
The renamed three options, however, set a group when they are pressed,
and this group remains set when the relevant key is released.
Keep the old names around as aliases, for backward compatibility.
Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>
|
|
They are incomplete because, for example, 'setxkbmap dvorak it' will
give you the American Dvorak layout, not the Italian one. They are
faulty because, for example, 'setxkbmap dvorak ca' fails (because the
rules expect the layout to be called "dvorak", not "fr-dvorak").
These rules may have been useful during a transition period of a few
years, but now they are just anomalies that distract from the basic
format of 'setxkbmap country-code variant-name'.
Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>
|
|
Eighteen years ago, in commit 1bdb65affc, the inaccurately named
option 'shift_toggle' was renamed to the better 'shifts_toggle',
and 'shift_toggle' was added as a convenience alias for existing
users of the option. For how long should such an alias be kept?
Ten years seems more than enough, so it's time to drop this one.
Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>
|
|
Stop hardcoding the Perl path to /usr/bin/perl. Not all systems have
Perl installed to /usr/bin, and some users might have installed Perl to
a custom location.
Instead, use /usr/bin/env, which performs a $PATH lookup to find the
Perl executable.
|
|
console-setup still relies on the xorg ruleset [1] and there may be other tools
out there. Let's provide an equivalent option to our autotools build to
install the xorg symlinks.
Note that unlike the autotools approach, only the "xorg" symlinks are
provided, not the well and truly legacy "xfree86" ones.
[1] https://salsa.debian.org/installer-team/console-setup/-/merge_requests/7/
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
This produces virtually the same installed tree as the autotools builds with
the following exceptions:
- rules symlinks is no longer supported. This option is 16y old and likely
hasn't been used in the last decade or so
- the xkeyboard-config.pc file uses expanded paths now, e.g.
xkb_base=/usr/share/X11/xkb
vs autotools'
xkb_base=${datarootdir}/X11/xkb
The values are the same for both so this is not a functional change.
- substitutions in the man page are hardcoded since we can't use the m4
XORG_MACROS. This appears to only matter for the miscmansuffix and there
only for solaris up to including 11.3. so... meh?
- the .mo files differ, but it's hard to say why since they're generated
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
|