Discussion:
xkb issue - types not recognized
cheater00 .
2014-05-19 10:40:04 UTC
Permalink
Hi everyone! I'm new to the list, but it looks very interesting
already! I was wondering if this was the right place to talk about
xkb?

I have an issue with xkb and i was hoping someone here might be able
to give me some pointers.

i have created a new keyboard layout with xkb and now i need to add
new types, i.e. how modifier keys behave. The symbols file, types file
and compat file seem to be well formed, but the types have no effect,
and when i check with setxkbmap and xkbcomp, the types are not listed.
I'm not sure how to edit the xml files in /usr/share/X11/xkb/rules so
that xkb knows how to find the new types. How should i proceed?

Debugging output can be found here: http://lpaste.net/5576643678098685952

the source is here:
https://bitbucket.org/cheater/us_split_cherry_kw6000_two_iso/src/

This is under Ubuntu; as I understand Ubuntu and some other distros
use rules/evdev.xml, whereas some other distros use an older system
which is also based off files in rules/.

The base contains an easy to use installer and it could be a base for
other people's layouts. It integrates with the UI.

I would appreciate any pointers, as I've probably read anything there
is online about xkb starting the last weekend, and am pretty much
stuck...

Thanks!
Jerome Leclanche
2014-05-19 11:23:32 UTC
Permalink
I think an x11-related list might get you some better answers. However
as it happens I made my own xkb layout a while ago. The bad news is I
never quite figured out how to install it as a separate layout, so
what I do is actually replace symbols/us with my layout.

I don't think you're supposed to edit anything in X11/xkb/rules, the
package manager ships all the files in there and nothing would survive
an xkb-common upgrade. To add insult to injury, xkb does not look in
$XDG_*_HOME dirs so you cannot install your keyboard layout locally.

The very unscalable advice I got a few years ago when asking an xkb
dev was "Just send us your layout and we'll add it upstream". I'm not
sure if the situation has improved since - if it has, please let me
know about it :)


J. Leclanche
Post by cheater00 .
Hi everyone! I'm new to the list, but it looks very interesting
already! I was wondering if this was the right place to talk about
xkb?
I have an issue with xkb and i was hoping someone here might be able
to give me some pointers.
i have created a new keyboard layout with xkb and now i need to add
new types, i.e. how modifier keys behave. The symbols file, types file
and compat file seem to be well formed, but the types have no effect,
and when i check with setxkbmap and xkbcomp, the types are not listed.
I'm not sure how to edit the xml files in /usr/share/X11/xkb/rules so
that xkb knows how to find the new types. How should i proceed?
Debugging output can be found here: http://lpaste.net/5576643678098685952
https://bitbucket.org/cheater/us_split_cherry_kw6000_two_iso/src/
This is under Ubuntu; as I understand Ubuntu and some other distros
use rules/evdev.xml, whereas some other distros use an older system
which is also based off files in rules/.
The base contains an easy to use installer and it could be a base for
other people's layouts. It integrates with the UI.
I would appreciate any pointers, as I've probably read anything there
is online about xkb starting the last weekend, and am pretty much
stuck...
Thanks!
_______________________________________________
xdg mailing list
http://lists.freedesktop.org/mailman/listinfo/xdg
cheater00 .
2014-05-19 12:26:14 UTC
Permalink
Hi Jerome,
Post by Jerome Leclanche
I think an x11-related list might get you some better answers. However
as it happens I made my own xkb layout a while ago. The bad news is I
never quite figured out how to install it as a separate layout, so
what I do is actually replace symbols/us with my layout.
thanks, I'll post this to xorg and separately xorg-devel. I'm not sure
which one applies.
Post by Jerome Leclanche
I don't think you're supposed to edit anything in X11/xkb/rules
From what I've read on the internet, some documents recommend adding
an xkb_keymap declaration in keymap/. Those files, if you look at
them, explicitly specify the types (or compats, not sure) that are
being used, so should work. Compiling by hand with xkbcomp should
work, but I don't want to do that, I want the OS to ingest the files
itself, and show them in the Gnome Keyboard Properties (actually I use
MATE, but that's exactly the same).

Then some documents say that was obsoleted by (non-xml) files in
rules/, e.g. rules/evdev and rules/evdev.lst, and then some say that
was obsoleted by xml files in rules/. You can see xkbcomp still
operates with xkb_keymap as the internal format. I assume this should
now be generated from the xml files somehow. This is what Gnome uses
as I understand.
Post by Jerome Leclanche
the package manager ships all the files in there and nothing would survive
an xkb-common upgrade. To add insult to injury, xkb does not look in
$XDG_*_HOME dirs so you cannot install your keyboard layout locally.
I have advice to the contrary: I've been using the layout this way -
having edited evdev.xml - for years now and it's worked through all
the package updates I got; not sure if anything updated xkb at all,
probably not. It also survived an upgrade from Ubuntu 12.04 to 13.04.
And even if it hadn't - I can always just type sudo ./install.py and
that's it!
Post by Jerome Leclanche
The very unscalable advice I got a few years ago when asking an xkb
dev was "Just send us your layout and we'll add it upstream". I'm not
sure if the situation has improved since - if it has, please let me
know about it :)
Do you remember who that was and where it was? Maybe I could email them.

Thanks!
Jerome Leclanche
2014-05-19 12:29:07 UTC
Permalink
Post by cheater00 .
Hi Jerome,
Post by Jerome Leclanche
I think an x11-related list might get you some better answers. However
as it happens I made my own xkb layout a while ago. The bad news is I
never quite figured out how to install it as a separate layout, so
what I do is actually replace symbols/us with my layout.
thanks, I'll post this to xorg and separately xorg-devel. I'm not sure
which one applies.
Post by Jerome Leclanche
I don't think you're supposed to edit anything in X11/xkb/rules
From what I've read on the internet, some documents recommend adding
an xkb_keymap declaration in keymap/. Those files, if you look at
them, explicitly specify the types (or compats, not sure) that are
being used, so should work. Compiling by hand with xkbcomp should
work, but I don't want to do that, I want the OS to ingest the files
itself, and show them in the Gnome Keyboard Properties (actually I use
MATE, but that's exactly the same).
Then some documents say that was obsoleted by (non-xml) files in
rules/, e.g. rules/evdev and rules/evdev.lst, and then some say that
was obsoleted by xml files in rules/. You can see xkbcomp still
operates with xkb_keymap as the internal format. I assume this should
now be generated from the xml files somehow. This is what Gnome uses
as I understand.
Post by Jerome Leclanche
the package manager ships all the files in there and nothing would survive
an xkb-common upgrade. To add insult to injury, xkb does not look in
$XDG_*_HOME dirs so you cannot install your keyboard layout locally.
I have advice to the contrary: I've been using the layout this way -
having edited evdev.xml - for years now and it's worked through all
the package updates I got; not sure if anything updated xkb at all,
probably not. It also survived an upgrade from Ubuntu 12.04 to 13.04.
And even if it hadn't - I can always just type sudo ./install.py and
that's it!
When you say "using the layout this way", what do you mean? I was
talking about editing files in ~/.local/share.
Post by cheater00 .
Post by Jerome Leclanche
The very unscalable advice I got a few years ago when asking an xkb
dev was "Just send us your layout and we'll add it upstream". I'm not
sure if the situation has improved since - if it has, please let me
know about it :)
Do you remember who that was and where it was? Maybe I could email them.
Thanks!
That was the x11 development channel on Freenode.

J. Leclanche
cheater00 .
2014-05-19 12:30:59 UTC
Permalink
Post by Jerome Leclanche
Post by cheater00 .
Hi Jerome,
Post by Jerome Leclanche
I think an x11-related list might get you some better answers. However
as it happens I made my own xkb layout a while ago. The bad news is I
never quite figured out how to install it as a separate layout, so
what I do is actually replace symbols/us with my layout.
thanks, I'll post this to xorg and separately xorg-devel. I'm not sure
which one applies.
Post by Jerome Leclanche
I don't think you're supposed to edit anything in X11/xkb/rules
From what I've read on the internet, some documents recommend adding
an xkb_keymap declaration in keymap/. Those files, if you look at
them, explicitly specify the types (or compats, not sure) that are
being used, so should work. Compiling by hand with xkbcomp should
work, but I don't want to do that, I want the OS to ingest the files
itself, and show them in the Gnome Keyboard Properties (actually I use
MATE, but that's exactly the same).
Then some documents say that was obsoleted by (non-xml) files in
rules/, e.g. rules/evdev and rules/evdev.lst, and then some say that
was obsoleted by xml files in rules/. You can see xkbcomp still
operates with xkb_keymap as the internal format. I assume this should
now be generated from the xml files somehow. This is what Gnome uses
as I understand.
Post by Jerome Leclanche
the package manager ships all the files in there and nothing would survive
an xkb-common upgrade. To add insult to injury, xkb does not look in
$XDG_*_HOME dirs so you cannot install your keyboard layout locally.
I have advice to the contrary: I've been using the layout this way -
having edited evdev.xml - for years now and it's worked through all
the package updates I got; not sure if anything updated xkb at all,
probably not. It also survived an upgrade from Ubuntu 12.04 to 13.04.
And even if it hadn't - I can always just type sudo ./install.py and
that's it!
When you say "using the layout this way", what do you mean? I was
talking about editing files in ~/.local/share.
The way it's done in my package - check it out, especially
installer.py, it should be self-explanatory. It copies some files to
/usr/share and edits evdev.xml. You should be able to use it for your
layout with only minor modifications :-)

Cheers!

Loading...