wofi(5)
π NAME π
wofi β configuration file and styling π
β¨ DESCRIPTION β¨
okay bestie, listen up, because wofi's config format is literally the easiest thing ever π«Ά It's just key value pairs in snake case. That's it. That's the whole vibe. No cap.
Most of the config options? They're the same as the command line options, so if you already know your flags you're already 90% of the way there π But β and this is the fun part β there's a small handful of options that you can only get to through wofi's config file. Those ones are the secret menu items, iykyk π₯
π Mode-Specific Options π
The built-in modes have their own special options, and those are documented over in wofi(7) π When you put them in the config file, they go in like this:
mode-example_opt=val
So for example: dmenu has an option called parse_action, and that one would be placed in the config as:
dmenu-parse_action=true
See? The mode name goes up front, then a dash, then the option. Slay β¨
π¬ Comments & Backslashes π¬
Anything that comes after a # is a comment and gets completely ignored π« ... unless that # is prefixed with a \. So \# is not a comment, bestie, it's you telling wofi "no fr, I mean this literally."
β οΈ And because of that whole situation, if you actually want a backslash in your config you have to escape it too, which gives you \\. Yes, the backslash needs a little buddy to survive in there π Don't ask, just do it.
β¨ CONFIG OPTIONS β¨
okay bestie, this is where the real magic lives. Most of these are just the command flags from wofi(1) but in snake_case, but some are unique to the config. iykyk. π«Ά
style=PATHβ Specifies the CSS file to use as the stylesheet. πstylesheet=PATHβ Specifies the CSS file to use as the stylesheet. But this is NOT the same asstyle. Absolute paths are absolute, however relative paths are relative to the wofi config folder location$XDG_CONFIG_HOME/wofiand NOT the current working directory as they are withstyle. They are also NOT relative to the path as specified by--conf. This option comes fromrootbarand is probably more confusing than it's worth. You should probably usestyleunless you're sure this is what you want. πcolor=PATHβ Specifies the colors file to use. πcolors=PATHβ Specifies the colors file to use. But this is NOT the same ascolor. Absolute paths are absolute, however relative paths are relative to the wofi config folder location$XDG_CONFIG_HOME/wofiand NOT the current working directory as they are withcolor. They are also NOT relative to the path as specified by--conf. This option comes fromrootbarand is probably more confusing than it's worth. You should probably usecolorunless you're sure this is what you want. πshow=MODEβ Specifies the mode to run in. A list of modes can be found inwofi(7). β¨mode=MODEβ Identical toshow. πwidth=WIDTHβ Specifies the menu width in pixels or percent of screen size, default is50%. Pixels are used unless the number ends with a%. πheight=HEIGHTβ Specifies the menu height in pixels or percent of screen size, default is40%. Pixels are used unless the number ends with a%. πprompt=PROMPTβ Sets the prompt shown in the search box, default is the name of the mode. π¬xoffset=OFFSETβ Sets the x offset from the location in pixels, default is0. βοΈx=OFFSETβ Identical toxoffset. πyoffset=OFFSETβ Sets the y offset from the location in pixels, default is0. βοΈy=OFFSETβ Identical toyoffset. πnormal_window=BOOLβ Iftrue, runs wofi in a normal window instead of usingwlr-layer-shell, default isfalse. πͺallow_images=BOOLβ Iftrue, allows image escape sequences to be processed and rendered, default isfalse. πΌοΈallow_markup=BOOLβ Iftrue, allows pango markup to be processed and rendered, default isfalse. π¨cache_file=PATHβ Specifies the cache file to load/store cache, default is$XDG_CACHE_HOME/wofi-<mode name>where<mode name>is the name of the mode, if$XDG_CACHE_HOMEis not specified~/.cacheis used. πΎterm=TERMβ Specifies the term to use when running a program in a terminal. This overrides the default terminal run order which iskitty,alacritty,wezterm,foot,termite,gnome-terminal,weston-terminalin that order. π₯οΈpassword=CHARACTERβ Runs wofi in password mode using the specified character, default isfalse. πexec_search=BOOLβ Iftrue, activating a search with enter will execute the search not the first result, default isfalse. πno_custom_entry=BOOLβ Iftrue, only entries will be submitted to modes, never the content of the search box, default isfalse. π«hide_scroll=BOOLβ Iftrue, hides the scroll bars, default isfalse. πmatching=MODEβ Specifies the matching mode, it can be eithercontains,strict-contains,multi-contains, orfuzzy, default iscontains. π§©insensitive=BOOLβ Iftrue, enables case insensitive search, default isfalse. πparse_search=BOOLβ Iftrue, parses out image escapes and pango preventing them from being used for searching, default isfalse. πlocation=LOCATIONβ Specifies the location. Seewofi(7)for more information, default iscenter. πno_actions=BOOLβ Iftrue, disables multiple actions for modes that support it, default isfalse. π¬lines=LINESβ Specifies the height in number of lines instead of pixels. πcolumns=COLUMNSβ Specifies the number of columns to display, default is1. ποΈsort_order=ORDERβ Specifies the default sort order. There are currently two orders,defaultandalphabetical. Seewofi(7)for details. π€gtk_dark=BOOLβ Iftrue, instructs wofi to use the dark variant of the current GTK theme (if available). Default isfalse. πsearch=STRINGβ Specifies something to search for immediately on opening. πmonitor=STRINGβ Sets the monitor to open on. π₯οΈpre_display_cmd=COMMANDβ Specifies a printf-like string which is used on the entries prior to displaying them. This command is only used to represent the label widget's string, and won't affect the output of the selected label. π·οΈorientation=ORIENTATIONβ Specifies the orientation, it can be eitherhorizontalorvertical, default isvertical. βοΈβοΈhalign=ALIGNβ Specifies the horizontal align for the entire scrolled area, it can be any offill,start,end, orcenter, default isfill. βοΈcontent_halign=ALIGNβ Specifies the horizontal align for the individual entries, it can be any offill,start,end, orcenter, default isfill. βοΈvalign=ALIGNβ Specifies the vertical align for the entire scrolled area, it can be any offill,start,end, orcenter, the default is orientation dependent. If vertical then it defaults tostart, if horizontal it defaults tocenter. βοΈfilter_rate=RATEβ Specifies the rate at which search results are updated in milliseconds, default is100. β±οΈimage_size=SIZEβ Specifies the size of images in pixels when images are enabled, default is32. πΌοΈkey_up=KEYβ Specifies the key to use in order to move up. Default isUp(Uparrow). Seewofi-keys(7)for the key codes. β¬οΈkey_down=KEYβ Specifies the key to use in order to move down. Default isDown(Downarrow). Seewofi-keys(7)for the key codes. β¬οΈkey_left=KEYβ Specifies the key to use in order to move left. Default isLeft(Leftarrow). Seewofi-keys(7)for the key codes. β¬ οΈkey_right=KEYβ Specifies the key to use in order to move right. Default isRight(Rightarrow). Seewofi-keys(7)for the key codes. β‘οΈkey_forward=KEYβ Specifies the key to use in order to move forward. Default isTab. Seewofi-keys(7)for the key codes. β©key_backward=KEYβ Specifies the key to use in order to move backward. Default isShift-ISO_Left_Tab(Shift+Tab). Seewofi-keys(7)for the key codes. βͺkey_submit=KEYβ Specifies the key to use in order to submit an action. Default isReturn. Seewofi-keys(7)for the key codes. βkey_exit=KEYβ Specifies the key to use in order to exit wofi. Default isEscape. Seewofi-keys(7)for the key codes. πͺkey_pgup=KEYβ Specifies the key to use in order to move one page up. Default isPage_Up. Seewofi-keys(7)for the key codes. πβ¬οΈkey_pgdn=KEYβ Specifies the key to use in order to move one page down. Default isPage_Down. Seewofi-keys(7)for the key codes. πβ¬οΈkey_expand=KEYβ Specifies the key to use in order to expand/contract multi-action entries. There is no default. Seewofi-keys(7)for the key codes. πͺkey_hide_search=KEYβ Specifies the key to use in order to hide/show the search bar. There is no default. Seewofi-keys(7)for the key codes. πkey_copy=KEYβ Specifies the key to use in order to copy the action text for the current entry. The default isCtrl-c. Seewofi-keys(7)for the key codes. πkey_custom_(n)=KEYβ Allows for configuring custom exit codes. For example settingkey_custom_0=Ctrl-0will make it so if you pressCtrl-0wofi will set its exit status to10. This will not cause wofi to exit, it will only set its exit code for when it does.20of these keys are configurable numbered0-19. The exit status used is10+nwherenis the number attached tokey_custom_n. There are no defaults for these. Seewofi-keys(7)for the key codes. π’line_wrap=MODEβ Specifies the line wrap mode to use. The options areoff,word,char, andword_char. Default isoff. πglobal_coords=BOOLβ Specifies whether x and y offsets should be calculated using the global compositor space instead of the current monitor. Default isfalse. This does not play well with locations and using it with them is not advised. πhide_search=BOOLβ Specifies whether the search bar should be hidden. Default isfalse. πclose_on_focus_loss=BOOLβ Specifies whether to quit wofi when it loses focus. Default isfalse. πͺdynamic_lines=BOOLβ Specifies whether wofi should be dynamically shrunk to fit the number of visible lines or if it should always stay the same size. Default isfalse. πlayer=LAYERβ Specifies the layer to open on. The options arebackground,bottom,top, andoverlay. Default istop. ποΈcopy_exec=PATHβ Specifies the executable to pipe copy data into.$PATHwill be scanned, this is not passed to a shell and must be an executable. Default iswl-copy. πsingle_click=BOOLβ Specifies whether or not actions should be executed on a single click or a double click. Default isfalse. π±οΈpre_display_exec=BOOLβ This modifies the behavior ofpre_display_cmdand causes the command in question to be directly executed viafork/execrather than through the shell. π΄use_search_box=BOOLβ Specifies whether or not wofi should use aGtkSearchEntryor a regularGtkEntry. The search entry has a little search icon and a clear text button that the regular entry lacks. Default istrue. π
β¨ CSS SELECTORS β¨
Okay bestie so literally any GTK widget can get picked up by using the name of its CSS node π β but lowkey, those names can shift around with updates and nobody promised they'd stay put. Not stable, no cap.
That said, wofi hands certain widgets specific names and classes so you can grab the important ones straight from CSS without playing detective. And if you wanna go full gremlin mode and use raw GTK widget names directly, wofi(7) has the current widget layout wofi is using, so go read that π.
#windowβ the name of the window itself. The main character. π#outer-boxβ the name of the box that contains literally everything.#inputβ the name of the search bar. Where you type. β¨οΈ#scrollβ the name of the scrolled window containing all of the entries.#inner-boxβ the name of the box containing all of the entries.#imgβ the name of all images in entries displayed in image mode. πΌοΈ#textβ the name of all the text in entries.#unselectedβ the name of all entries currently unselected. Tho ngl a better way of doing this is to do#entryand combine that with#entry:selected.#selectedβ the name of all entries currently selected. Same thing here: a better way of doing this is to do#entry:selected. π.entryβ the class attached to all entries. It's attached to the inside property box and it's old, so you probably want#entryinstead. Respectfully, it's giving legacy.#entryβ the name of all entries.#expander-boxβ the name of all boxes shown when expanding entries with multiple actions.
π COLORS π
So the colors file is formatted as hex values separated by new lines. These values should be in the standard HTML format and begin with a hash #. Wofi will load these colors, however wofi has zero idea what color should be used for what π so you must reference them from your CSS yourself. It's not gonna read your mind, bestie.
You can reference these from your CSS by doing --wofi-color<n> where <n> is the line number - 1. So for example, to reference the color on line 1 you would do --wofi-color0. Yes, zero-indexed. That's just the vibe. β¨
The colors can also be referenced by doing --wofi-rgb-color<n> where <n> is the line number - 1. The difference between these two is the format used to replace the macro:
--wofi-color<n>gets replaced with an HTML color code in the format#FFFFFF.--wofi-rgb-color<n>gets replaced with comma separated rgb values in the format255, 255, 255.
The correct usage of --wofi-rgb-color<n> is to wrap it in rgb() or rgba(). And heads up β it does not return an alpha value, so combining it with rgba() should be done like so:
rgba(--wofi-rgb-color0, 0.8)
That would set the color to line 1 with an opacity of 80%. Cute, right? π
And that's the whole page, bestie β you made it to the end π¦ This was all from the wofi(5) manual page (wofi's file formats section, section 5), so go forth and style your little heart out. Periodt. π
πΈ
π¦ where this page comes from
- alpine 3.24: wofi-doc 1.5.3-r0 Β· GPL-3.0-only
- arch rolling: wofi 1.5.3-1 Β· GPL-3.0-or-later
- fedora 43: wofi 1.5.3-1.fc43 Β· GPL-3.0-only
- fedora 43: wofi 1.5.3-1.fc43 Β· GPL-3.0-only
- fedora 44: wofi 1.5.3-2.fc44 Β· GPL-3.0-only
- fedora 44: wofi 1.5.3-2.fc44 Β· GPL-3.0-only
- nixos 26.05: wofi 1.5.3
- nixpkgs unstable: wofi 1.5.3
- ubuntu resolute: wofi 1.5.1-1 Β· GPL-3.0-or-later
- ubuntu stonking: wofi 1.5.3-1 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms