Get a list of available Keyboard Models and Layouts on Linux

Most Linux distributions come with the X keyboard extension (XKB) which is part of the X Window System. Fortunately for us the XKB provides a parsable list of all available keyboard models and layouts in /usr/share/X11/xkb/rules/base.xml. I threw together a Java class that makes use of JAXB to parse this file:

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.