New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to write methods in config.py #1748
Comments
tried with CommandClient but it looks like Qtile is still not initialized |
I think you just have to iterate on |
ok, error is gone but bar backgrouns is not change. I even tried to set background in config, but it looks it doesn't react on that. Other thing is And |
That hook can get access to the Qtile instance if you define it in your
As for the background not changing - widgets take their background from the bar's background only if they don't have their own set so I'd check that. Otherwise, maybe confirm that the widgets' draw methods are being called? |
Related to #1719 |
Yes, but what a nasty hack! |
I think it would be much simpler for you to add a That being said, I do find this interesting because it's yet another example to me that it's overly complicated to interact with the different Qtile objects from the configuration and that we have something wrong. I'm opening another issue one this subject. |
the lasts code:
makes it quite simple, just needs to take right hook |
To me this just seems like we really do need to fix #1719. |
@tych0 you mean to add |
The title of the bug is "more sensible". I think adding the qtile object to all hooks is probably a good idea, but also for example current_screen_change should also receive the screen that is now focused. setgroup should get the newly focused group, etc. |
This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 30 days. |
The |
Issue description
Wanted to write method that should be run on hook and at start up: change top bar background color (indicate active/inactive screen).
Later solved issue could be transformed into documentation :)
Qtile version
0.15.1.dev122+gaaebfb55
Stack traces
Configuration
The text was updated successfully, but these errors were encountered: