elParaguayo / qtile-extras

Somewhere to store things I create for qtile that probably won't end up in the official repo
MIT License
166 stars 21 forks source link

PulseWidgetExtra behaving weirdly #287

Open Sprinter05 opened 1 year ago

Sprinter05 commented 1 year ago

Using qtile-git and qtile-extras-git (latest version) The PulseWidgetExtra widget does not work in neither 'icon' nor 'both' mode getting the following error:

2023-10-15 18:53:15,931 WARNING libqtile bar.py:__init__():L28 There is no longer a need to use qtile_extras.bar.Bar. Please update your config to use libqtile.bar.Bar.
2023-10-15 18:53:15,941 WARNING libqtile bar.py:__init__():L28 There is no longer a need to use qtile_extras.bar.Bar. Please update your config to use libqtile.bar.Bar.
2023-10-15 18:53:15,958 ERROR libqtile base.py:_configure():L141 You must set the `theme_path` when using icons
2023-10-15 18:53:15,958 ERROR libqtile bar.py:_configure_widget():L375 PulseVolumeExtra widget crashed during _configure with error:
Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/libqtile/bar.py", line 366, in _configure_widget
    widget._configure(self.qtile, self)
  File "/usr/lib/python3.11/site-packages/qtile_extras/widget/decorations.py", line 869, in new_configure
    self.old_configure(qtile, bar)
  File "/usr/lib/python3.11/site-packages/qtile_extras/widget/pulse_extra.py", line 59, in _configure
    _Volume._configure(self, qtile, bar)
  File "/usr/lib/python3.11/site-packages/qtile_extras/widget/base.py", line 142, in _configure
    raise confreader.ConfigError("No theme_path provided.")
libqtile.confreader.ConfigError: No theme_path provided.

Current config for the widget:

widget.PulseVolumeExtra(
                    mode='icon',
                    theme_path=None,
                    emoji=True,
                    emoji_list=['🔇', '🔈', '🔉', '🔊'],
                ),

Also when using the 'bar' mode there are a lot of graphical glitches like the bar becoming a clone of the SysTray widget or the bar simply freezing. The widget does still provide its functionality even during this state.

elParaguayo commented 1 year ago

For the bit about icons, the log tells you the problem: "You must set the theme_path when using icons". That means it can't be None and needs to be a path to a folder containing the correct icons.

I note you've used emoji=True. That's missing from the qtile-extras version at the moment so I should add that.

As for "bar" mode, I can't replicate this. Can you share your full config so I can try running that?

Sprinter05 commented 1 year ago

I did not set a theme_path because I was intending to use emotes not a theme so it shouldn't be needed. But if you have not added emojis yet I can see why. Respecting the config it might be due to it being inside a decoration which is why it is behaving weirdly.

careb0t commented 1 month ago

I am also having this issue with the PulseWidgetExtra widget, but I am not quite sure how to implement icons for theme_path. Is there a specific number of icons required? A specific format? Specific file names? I have looked through the documentation for both the regular Qtile docs, and Qtile extras docs, but the only thing mentioned is that you need to provide a path for theme_path, but nothing about what should be in that path.

elParaguayo commented 1 month ago

I am also having this issue with the PulseWidgetExtra widget, but I am not quite sure how to implement icons for theme_path. Is there a specific number of icons required? A specific format? Specific file names? I have looked through the documentation for both the regular Qtile docs, and Qtile extras docs, but the only thing mentioned is that you need to provide a path for theme_path, but nothing about what should be in that path.

This isn't qtile-extras specific as the icons are supported in the default PulseVolume widget.

theme_path should be the path to a folder containing icons with the following names:

        names = (
            "audio-volume-high",
            "audio-volume-low",
            "audio-volume-medium",
            "audio-volume-muted",
        )