Skip to content
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

desktop-managers: Use a black BG as fallback #25101

Merged
merged 1 commit into from Apr 29, 2017

Conversation

primeos
Copy link
Member

@primeos primeos commented Apr 21, 2017

Use a solid black background when no background image (via
~/.background-image) is provided. In my case this fixes the really
strange behaviour when i3 without a desktop-manager starts with the SDDM
login screen as background image.

Motivation for this change

Minimal windows managers like i3 won't touch the root window. Using a display manager this seems to cause problems as they alter the root window (at least SDDM does). The result is something like this (note the i3 status-bar at the bottom):
img_20170416_184025

Using this patch i3 will "launch" with a (solid) black background when ~/.background-image isn't present. I actually wonder if we should drop the ~/.background-image support since it requires an additional program (feh) and isn't documented in the NixOS manual. But since most users running a minimal WM like i3 will probably use feh anyway it shouldn't really matter.

Things done
  • Tested using sandboxing
    (nix.useSandbox on NixOS,
    or option build-use-sandbox in nix.conf
    on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • Linux
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@mention-bot
Copy link

@primeos, thanks for your PR! By analyzing the history of the files in this pull request, we identified @nbp, @edolstra and @peti to be potential reviewers.

Use a solid black background when no background image (via
~/.background-image) is provided. In my case this fixes the really
strange behaviour when i3 without a desktop manager starts with the SDDM
login screen as background image.
@primeos primeos force-pushed the desktop-manager-background-fix branch from bd24fe4 to 8528136 Compare April 29, 2017 17:04
@primeos primeos merged commit 8528136 into NixOS:master Apr 29, 2017
@cleverca22
Copy link
Contributor

also, there is no way to remove the feh dependency
nixos will iterate over every manager you have enabled, to detect if at least one doesn't set its own background, then add feh to do things for you

but the 'none' manager is always on, and doesn't support that, making the auto-detection always force feh in

@primeos
Copy link
Member Author

primeos commented May 31, 2017

@cleverca22 Why shouldn't we be able to remove the feh dependency? This seems to be the only module referencing feh and we could simply drop it (bad solution) or replace it with xsetroot (better) - But as noted above I don't think there would be a real benefit anyway.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants