mirror of
https://github.com/gryf/wmaker.git
synced 2026-04-09 17:33:32 +02:00
wmaker: revamp titlebar language button
This patch is replacing the modelock legacy hardcoded language dropdown icons with a compact titlebar button based on the current locale. (it adds also a detection to xkbfile library which is required to get the short name of the locale). Now supports up to 4 layouts, clicking on the language button will cycle through them (XKB officially supports up to four groups).
This commit is contained in:
committed by
Carlos R. Mafra
parent
29177f94ed
commit
ec115fedf7
@@ -80,7 +80,7 @@ typedef struct WFrameWindow {
|
||||
WPixmap *lbutton_image;
|
||||
WPixmap *rbutton_image;
|
||||
#ifdef XKB_BUTTON_HINT
|
||||
WPixmap *languagebutton_image;
|
||||
WPixmap *languagebutton_image[2]; /* focused, unfocused */
|
||||
#endif
|
||||
|
||||
union WTexture **title_texture;
|
||||
@@ -93,6 +93,7 @@ typedef struct WFrameWindow {
|
||||
#ifdef KEEP_XKB_LOCK_STATUS
|
||||
int languagemode;
|
||||
int last_languagemode;
|
||||
char language_label[3]; /* 2-letter language code */
|
||||
#endif /* KEEP_XKB_LOCK_STATUS */
|
||||
|
||||
/* thing that uses this frame. passed as data to callbacks */
|
||||
|
||||
Reference in New Issue
Block a user