Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have just switched from Fluxbox to giving xmonad a go, and I am definitely liking it. However, the one thing I haven't managed to do is to change my desktop background.

I am using Ubuntu 8 (uh, can't remember the value after the point), and I installed xmonad through the package manager, and then ran xmonad from the list of environments available on the login screen.

I have tried setting it using gconftool as suggested on the Haskell wiki, but it doesn't seem to have any effect.

share|improve this question
up vote 30 down vote accepted

Regarding prior comment from grawity, the correct syntax is actually

xloadimage -onroot -fullscreen <>

The advantages over xloadiamge on xpmroot are:

  • allows png images
  • on Ubuntu, has its own package, rather than bein contained in the larger fvwm package

(sorry if this would be better as a comment on previous answer: I can't add comments)

share|improve this answer
I'm new to Haskell and Xmonad, and not exactly sure how to use that command in my Xmonad config. How am I supposed to use xloadimage? – E-rich May 30 '12 at 21:12
Ubuntu 12.04, didn't fill if the image aspect ratio wasn't the same as my monitor's. – cmc Feb 5 '13 at 13:22
@E-rich, put it in your .xinitrc file, usually before a line alike exec /bin/xmonad. – JMCF125 Jan 6 '14 at 19:27

I had some trouble with xloadimage (didn't work at all) and xpmroot (only accepts xpms and gimp wrote a strange one that it barfed on), but feh --bg-fill worked wonderfully (thanks to some guys on the arch forum).

share|improve this answer
Worked perfectly! Ubuntu 12.04. – cmc Feb 5 '13 at 13:22
perfect! it even works with dual monitors! – John C Aug 8 '13 at 15:13
yes, it also works with larger images on smaller screens (fit a 1920 image on a 1440 screen perfectly) – Johnson Steward Jan 15 at 15:16

Does this command work: xpmroot ~/background.xpm &? Where background.xpm is the filename of the image you want to be your background.

share|improve this answer
Yup, thanks. [15 chars] – Yacoby Nov 5 '09 at 0:46
Btw, I am not sure if that stays as your background after logging out. You might need to add that command to your ~/.xsessions or ~/.xinitrc – Alvin Row Nov 5 '09 at 0:52
For image formats other than XPM, xloadimage -root $path – grawity Nov 5 '09 at 15:47

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .