|
Common structure of XKB configuration files.The XKB configuration file can have one of three forms: Simple configuration.If file contain the "simple configuration" there must begins from heading like [ Flags ] FileType [ Name ] after which instructions follows. For example:xkb_keyУodes <TLDE> = 49; <AE01> = 10; ....... Set of simple sections.But often another form is used that is sequence of "simple sections". In such file all instruction are grouped to blocks or section that are bounded by figure brackets '{...}'. And each section must be terminated by semicolon sign ';'. Each section has own heading the same as for "simple configuration" file. [ Flags ] FileType [ Name1 ] '{' [ instructions ] '};' [ Flags ] FileType [ Name2 ] '{' [ instructions ] '};' ... For example:xkb_symbols "basic" {....}; xkb_symbols "us" {....}; .... File types.Both mentioned formats uses the same File Types. It can be one of five words:
Note that if file consists of some sections all sections must have the same type. But, of course, they have different names. Name in heading is any character string in double quotes. You can see that FileType in headings must presents always but Name can be ommited. Of course, if file is "simple configuration" or contains only one section the name presence is not necessary. To refer to this section in X-server configuration file the file name specifying is enough. But if there are some sections in one file they has to have differnt names. To refer to particular section it can be specified like file_name(section_name) for example:us(pc104) Flags.Each heading can contain some flags such as:
The next flags makes sense only for xkb_symbols type files and sections. They only marks kind of symbols this section contains.
I should note that X-server (or xkbcomp program) can use only default flag becouse it can help to choose needed section. All other flags are needed rather for users for navigation in lot of files and sections. By the way, complete list of all sections with their flags you can find in *.dir files inside {XROOT}/lib/X11/xkb directory. These files names reflects XKB file types - keycodes, types, symbols, etc. Flags in these files are represented by one letter that is first letter in flag name. Set of complex sections.And finally lets consider third type of configuration file that is sequence of "complex sections". Each "Complex section" has form the same as "simple section": [ Flags ] ComplexType [ Name ] '{' Section { Section } '};' but contains not instruction but blocks of simple type sections. For examplexkb_keymap "complete" { xkb_keycodes {...}; xkb_types {...}; xkb_compat {...}; xkb_symbols {...}; xkb_geometry {...}; }; Like simple sections file this file can contain some sections of the same type but with different names (one of sections can be marked by "default" flag). There are three "complex types":
|