xkblayout-state is a small program to get/set the current XKB keyboard layout. It's a thin wrapper around a modified version of Jay Bromley's XKeyboard class, the original of which is included in the following package: http://members.dslextreme.com/users/jbromley/files/ruby-xkb.tar.bz2 To compile, just say: make For usage instructions start the program without arguments. xkblayout-state is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.