waybar-niri-language(5)
๐ NAME ๐
okay bestie, gather round โ this is the manual for the waybar niri language module, aka waybar-niri-language(5). Yes it's a whole file formats manual, and yes it's iconic. ๐
๐ธ DESCRIPTION ๐ธ
The language module displays the language you've currently got selected in niri. That's it, that's the whole vibe โ it's the little bar widget that keeps you posted on which layout is live rn. ๐ฆ
โจ CONFIGURATION โจ
You hook this module up by addressing it as niri/language. That's the key, no cap. ๐
formatโ typeof:string, default:{}. This is the format, bestie โ it's how information should be displayed. ๐format-<lang>โ typeof:string. Gives you an alternative name to display per language, where<lang>is the language of your choosing. You can pass this multiple times with multiple languages, exactly like the example below is doing (and it ate, ngl). โจmenuโ typeof:string. The action that popups the menu. ๐ซถmenu-fileโ typeof:string. The location of the menu descriptor file. There needs to be an element of typeGtkMenuwith idmenuโ like, that's non-negotiable, so don't forget it. ๐menu-actionsโ typeof:array. The actions corresponding to the buttons of the menu. ๐expandโ typeof:bool, default:false. Turns on this module being able to consume all the left over space, dynamically. It's giving main character energy, it takes up the room. ๐
๐ฎ FORMAT REPLACEMENTS ๐ฎ
These are the little placeholders you can drop into your format, and they all slay:
{short}โ short name of layout (e.g."us"). Fun fact: it equals{}. ๐{shortDescription}โ short description of layout (e.g."en"). ๐ธ{long}โ long name of layout (e.g."English (Dvorak)"). ๐{variant}โ variant of layout (e.g."dvorak"). ๐ฆ
๐ EXAMPLES ๐
Not me showing you exactly how to serve looks with this config:
"niri/language": {
"format": "Lang: {long}",
"format-en": "AMERICA, HELL YEAH!",
"format-tr": "As bayraklarฤฑ"
}
๐ STYLE ๐
#language
AND โ here's the extra cute part โ a CSS class matching the current layout's short name gets added to the widget. So you can do per-language styling, fr fr, like this:
#language.us { color: #00ff00; }
#language.de { color: #ff0000; }
#language.fr { color: #0000ff; }
mwah ๐ okay that's the whole page โ go forth and style your bar. This has been waybar-niri-language(5), dated 2026-02-08, and honestly? obsessed. bye bestie ๐ซถโจ
๐ฆ where this page comes from
- ubuntu resolute: waybar 0.15.0-1 ยท MIT
- ubuntu stonking: waybar 0.15.0-1 ยท MIT
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms