QTILE - File paths in widgets break qtile
by zkwrtl from LinuxQuestions.org on (#5DCR5)
Hello.
I'm trying to make use of Qtile's BatteryIcon widget.
Part of the doc states that I can pass a 'theme_path' arg in the widget function. Whenever I specify a path and restart qtile, qtile will only render the current screen and a cursor. Keys and Bar disappear until I remove the path from config.py and restart the qtile session.
Troubleshooting:
2021-01-27 14:17:31,866 WARNING libqtile xcursors.py:_setup_xcursor_binding():L112 xcb-cursor not found, fallback to font pointerconfig.py snippit
Code:import os
import re
import socket
import subprocess
from libqtile.config import Drag, Key, Screen, Group, Drag, Click, Rule
from libqtile.command import lazy
from libqtile import layout, bar, widget, hook
from libqtile.widget import Spacer
home = os.path.expanduser('~')
icon_path =home + "/.config/qtile/graphics/icons"
...
screens = [
Screen(
bottom=bar.Bar(
[
widget.CurrentLayout(),
widget.GroupBox(),
widget.Prompt(),
widget.WindowName(),
widget.Chord(
chords_colors={
'launch': ("#ff0000", "#ffffff"),
},
name_transform=lambda name: name.upper(),
),
#widget.TextBox("default config", name="default"),
#widget.TextBox("Press <M-r> to spawn", foreground="#d75f5f"),
widget.Systray(),
widget.BatteryIcon(theme_path=icon_path),
widget.Volume(),
widget.Clock(format='%Y-%m-%d %a %I:%M %p'),
widget.QuickExit(),
],
24,
),
),
]
...


I'm trying to make use of Qtile's BatteryIcon widget.
Part of the doc states that I can pass a 'theme_path' arg in the widget function. Whenever I specify a path and restart qtile, qtile will only render the current screen and a cursor. Keys and Bar disappear until I remove the path from config.py and restart the qtile session.
Troubleshooting:
- I know my syntax is correct, because I can execute 'python3 config.py' without any errors
- qtile.log does not produce any relevant information either
2021-01-27 14:17:31,866 WARNING libqtile xcursors.py:_setup_xcursor_binding():L112 xcb-cursor not found, fallback to font pointerconfig.py snippit
Code:import os
import re
import socket
import subprocess
from libqtile.config import Drag, Key, Screen, Group, Drag, Click, Rule
from libqtile.command import lazy
from libqtile import layout, bar, widget, hook
from libqtile.widget import Spacer
home = os.path.expanduser('~')
icon_path =home + "/.config/qtile/graphics/icons"
...
screens = [
Screen(
bottom=bar.Bar(
[
widget.CurrentLayout(),
widget.GroupBox(),
widget.Prompt(),
widget.WindowName(),
widget.Chord(
chords_colors={
'launch': ("#ff0000", "#ffffff"),
},
name_transform=lambda name: name.upper(),
),
#widget.TextBox("default config", name="default"),
#widget.TextBox("Press <M-r> to spawn", foreground="#d75f5f"),
widget.Systray(),
widget.BatteryIcon(theme_path=icon_path),
widget.Volume(),
widget.Clock(format='%Y-%m-%d %a %I:%M %p'),
widget.QuickExit(),
],
24,
),
),
]
...