wallpaper
Set the desktop background image
SYNOPSIS
wallpaper [options] [file | directory]
wallpaper --set-color #RRGGBB
wallpaper --clear
wallpaper --list
PARAMETERS
--set
Set a specific image file as the wallpaper.
--set-random
Choose a random image from the specified directory and set it as wallpaper.
--set-color <#RRGGBB>
Set a solid background color using a hexadecimal RGB value.
--clear
Clear the current wallpaper, often reverting to a default or solid color.
--mode
Specify the display mode for the image. Common modes include fill, stretch, center, tile, zoom.
--list
Display information about the currently set wallpaper.
--monitor
Specify the monitor to set the wallpaper on (e.g., 0 for primary).
--help
Show a help message and exit.
--version
Display version information and exit.
DESCRIPTION
The wallpaper command provides a unified command-line interface for setting, managing, and querying desktop wallpapers across various Linux desktop environments. While many environments have their own specific tools (like gsettings for GNOME or xfconf-query for XFCE), this conceptual wallpaper utility aims to abstract these differences, offering a consistent way to control the desktop background. It supports setting static image files, selecting images from a directory, applying solid colors, and configuring display modes such as fill, stretch, center, or tile. Users can also use it to retrieve information about the currently set wallpaper. Designed for scripting and quick changes, wallpaper simplifies the process of customizing your desktop appearance without needing to navigate graphical settings.
CAVEATS
It is important to note that a single, universal wallpaper command is not standard across all Linux distributions and desktop environments. This description represents a conceptual utility that abstracts the various environment-specific methods.
In practice, users typically rely on:
Desktop Environment Specific Tools: GNOME uses gsettings or gnome-control-center, KDE uses qdbus or kde-plasma-desktop-settings, XFCE uses xfconf-query, LXDE uses pcmanfm --set-wallpaper.
Standalone Utilities: Tools like feh (feh --bg-fill image.jpg) or nitrogen are popular for lightweight window managers (e.g., Openbox, i3, AwesomeWM).
Therefore, if you try to execute wallpaper directly, it will likely result in a 'command not found' error unless you have installed a specific third-party utility or a custom script named wallpaper.
CONFIGURATION FILES
Many desktop environments and wallpaper setters save their configurations in specific files (e.g., DConf for GNOME, ~/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-desktop.xml for XFCE). Direct manipulation of these files is generally not recommended as it can lead to inconsistencies.
DISPLAY SERVERS
The underlying mechanism for displaying wallpapers depends on the display server in use (X11 or Wayland). Tools like feh primarily interact with X11, while Wayland compositors often handle backgrounds differently, requiring compositor-specific tools or protocols.
HISTORY
As a universal command, wallpaper does not have a single, unified development history. Instead, the functionality it represents has evolved within individual desktop environments and through the development of various standalone utilities designed to manage background images. Early desktop environments provided graphical tools, and later, command-line interfaces emerged as part of their configuration systems (e.g., gsettings becoming the standard for GNOME3+). Dedicated wallpaper utilities like feh and nitrogen gained popularity in the early 2000s for their flexibility and minimal dependencies, catering to users of more lightweight window managers. The desire for a consistent CLI approach continues to inspire community-driven scripts and custom solutions, but no single standard wallpaper command has been universally adopted.