Re: Fetching symbols information with XKBlib
Ivan Pascal <[email protected]>
| Newsgroups | gmane.comp.xfree86.devel |
|---|---|
| Message-ID | <[email protected]> |
Hello, > But I can't find a way to ask about current symbols. I just want to receive > short description like 'ru' or 'en' (or any other information which may be > used to identify current symbols) - is there a way to get it ? You can fetch names of groups that are symbolic names specified in xkb/symbols/* files like name[Group1] = "Russian"; The function for getting these names is XkbGetNames(dpy, XkbGroupNamesMask, xkb); where 'xkb' is a pointer (XkbDescrPtr) to some structure 'XKB Description'. You have to allocate this decription structure with XkbAllocKeyboard(void) before XkbGetNames call. If XkbGetName is completed successfully the names will appear in the array of Atoms xkb->names->groups[] -- Ivan U. Pascal | e-mail: [email protected] Administrator of | Tomsk State University University Network | Tomsk, Russia