Skip to main content

i3-workspace-names-daemon

This script dynamically updates i3wm workspace names based on the names of the windows therein.

It also allows users to define an icon to show for a named window from the Font Awesome icon list.

tl;dr

update i3-bar workspace names to look something like this

install

Install the package from pypi with pip.

sudo pip3 install i3-workspace-names-daemon

NB. if you don't have sudo privileges instead do

pip3 install --user i3-workspace-names-daemon
font

Install the Font Awesome font via your favourite package manager. This is necessary if you want to show an icon instead of a window's name in the i3 status bar.

For Debian/Ubuntu et al.

sudo apt install fonts-font-awesome

NB: if the glyphs are not rendering make sure the font is installed.

i3 config

Add the following line to your ~/.i3/config.

exec_always --no-startup-id exec i3-workspace-names-daemon

If you use the $mod+1 etc. shortcuts to switch workspaces then update the following so that the switch to workspace and move focussed window to workspace shortcuts still work.

from

bindsym $mod+1 workspace 1
bindsym $mod+Shift+1 move container to workspace 1
# etc

to

bindsym $mod+1 workspace number 1
bindsym $mod+Shift+1 move container to workspace number 1
# etc

icons config

Configure what icons to show for what application-windows in the file ~/.i3/app-icons.json or ~/.config/i3/app-icons.json (in JSON format). For example:

chris@vulcan: ~$ cat ~/.i3/app-icons.json
{
    "firefox": "firefox",
    "chromium-browser": "chrome",
    "chrome": "chrome",
    "google-chrome": "chrome",
    "x-terminal-emulator": "terminal",
    "thunderbird": "envelope",
    "jetbrains-idea-ce": "edit",
    "nautilus": "folder-open",
    "clementine": "music",
    "vlc": "play",
    "signal": "comment",
    "_no_match": "question",
}

where the key is the name of the i3-window (ie. what is shown in the i3-bar when it is not configured yet) and the value is the font-awesome icon name you want to show instead, see picking icons.

Note: the hard-coded list above is used if you don't add this icon-config file.

matching windows

You can debug windows names with xprop

Windows names are detected by inspecting in the following priority

  • name
  • title
  • instance
  • class

If there is no window name available a question mark is shown instead.

Another (simpler) way for debugging window names is running this script with -v or --verbose flag, it is suggested to use a terminal emulator that supports unicode (eg. kitty or urxvt)

unrecognised windows

If a window is not in the icon config then by default the window title will be displayed instead.

The maximum length of the displayed window title can be set with the command line argument --max_title_length or -l.

To show a specific icon in place of unrecognised windows, specify an icon for window _no_match in the icon config. If you want to show only that icon (hiding the name) then use the --no-match-not-show-name or -n option.

picking icons

The easiest way to pick an icon is to search for one in the gallery. NB: the "pro" icons are not available in the debian package.

windows delimiter

The window delimiter can be specified with -d or --delimiter parameter by default it is |.

Release files for i3-workspace-names-daemon 0.15.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for i3-workspace-names-daemon 0.15.0
File Size Uploaded
i3-workspace-names-daemon-0.15.0.tar.gz 17.2 kB Details

Release files / i3-workspace-names-daemon-0.15.0.tar.gz

Download URL i3-workspace-names-daemon-0.15.0.tar.gz
Size 17.2 kB
Tags Source
SHA-256 checksum
How to use checksums
25956d6864315e1b22a6732443d1f5db63fd0594cc43112e204f055aed1ba0df
BLAKE2b-256 checksum
How to use checksums
db5858da6e7ff214c4ccc16d852b0c100b04616f4932f90901a39abea50bbb62
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/41.0.0 requests-toolbelt/0.8.0 tqdm/4.31.1 CPython/2.7.15+

Release history Release notifications | RSS feed

This release

0.15.0 This release

1 release file

0.14.0

1 release file

0.13.0

1 release file

0.12.0

1 release file

0.11.0

1 release file

0.10.0

1 release file

0.9.0

1 release file

0.8.0

1 release file

0.7.0

1 release file

0.6

1 release file

0.5

1 release file

0.4

1 release file

0.3

1 release file

0.2

1 release file

0.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page