Bug 17184

Summary: Layout aliases are not properly loaded
Product: xkeyboard-config Reporter: Igor Stirbu <igor.stirbu>
Component: GeneralAssignee: xkb
Status: RESOLVED DUPLICATE QA Contact:
Severity: normal    
Priority: medium CC: andreimpopescu, daniel
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Igor Stirbu 2008-08-18 01:52:27 UTC
Hello,

In the current state the layouts are defined in symbols/xx files
and the aliases are specified in rules/compat/variantRename.lst.

There is a problem in configuring xkeyboard using aliases. These
errors are present when configured either with setxkbmap or by
writing the rules in /etc/X11/xorg.conf. There was a suggestion
that something may be wrong with setxkbmap but I tend to rule that
out as it is a query tool and doesn't do much in order to mess
things up.

So, here is a command that tries to load a configuration by using
the alias named 'comma'.

$ setxkbmap -layout us,ro -variant ,comma -print
xkb_keymap {
	xkb_keycodes  { include "xfree86+aliases(qwerty)"	};
	xkb_types     { include "complete"	};
	xkb_compat    { include "complete"	};
	xkb_symbols   { include "pc+us+ro(basic):2+ro(comma):2+group(menu_toggle)+ctrl(nocaps)"	};
	xkb_geometry  { include "pc(pc104)"	};
};

It can be seen that the xkb_symbols is not correctly composed. The
same info is printed if xorg.conf contains the following lines and
setxkbmap is called just to print the current configuration.

Option "XkbLayout"  "us,ro"
Option "XkbVariant" ",comma"

And the following message can be observed in the X log:

The XKEYBOARD keymap compiler (xkbcomp) reports:
> Error:            No Symbols named "comma" in the include file "ro"
>                   Exiting
>                   Abandoning symbols file "default"

I have to mention that this is not specific to Romanian layout. I've
tested this with Irish layout and the bug is reproducible. Try this:

setxkbmap -layout us,ie -variant ,basic
setxkbmap -layout us,ie -variant ,laptop

or any other alias.

Besides this, I have two additional notes that I would like to mention.

1. In addition the the above X message, I suppose the following
message may be related to the incorrect loading of keyboard layouts:

The XKEYBOARD keymap compiler (xkbcomp) reports:
> Warning:          Type "ONE_LEVEL" has 1 levels, but <RALT> has 2 symbols
>                   Ignoring extra symbols


2. I have observed that the Russian layout file has a layout
named 'legacy' which looks like this:

partial alphanumeric_keys
xkb_symbols "legacy" {
    include "ru(common)"
    name[Group1]= "Russia - Legacy";
};

This is similar to what I've proposed but is not considered a good
solution. Is it possible to use similar configuration until the issue
with aliases is fixed?

Thanks,
Igor
Comment 1 Sergey V. Udaltsov 2009-01-02 14:12:01 UTC
There is a general problem about compatibility rules...

*** This bug has been marked as a duplicate of bug 8459 ***
Comment 2 Sergey V. Udaltsov 2009-01-02 14:13:03 UTC
sorry, wrong bug number

*** This bug has been marked as a duplicate of bug 8452 ***

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.