NAME
App::MathImage::X11::Protocol::XSetRoot -- set root window background
SYNOPSIS
use App::MathImage::X11::Protocol::XSetRoot;
App::MathImage::X11::Protocol::XSetRoot->set_background
(X => $X11_protocol_object,
rootwin => $root_xid,
pixmap => $pixmap_xid,
allocated_pixels => $bool);
# now don't use $X11_protocol_object connection any more
DESCRIPTION
This module uses an X11::Protocol connection object to set the root window background in the style of the xsetroot program.
FUNCTIONS
App::MathImage::X11::Protocol::XSetRoot->set_background (key=>value, ...)-
Set the root window background to a pixmap or a pixel. The key/value parameters are
X => X11::Protocol object display => string ":0:0" etc rootwin => XID of root window, otherwise default pixmap => XID of pixmap to display pixel => integer pixel value allocated_pixels => boolean, default falseXis theX11::Protocolconnection, ordisplayis a display name to connect to, or otherwise the default display per$ENV{'DISPLAY'}is used.pixmapis the XID of a pixmap to set as the background, orpixelis an integer pixel value. One of the two is mandatory.If
allocated_pixelsis true thenpixelor some of the pixels inpixmaphave been allocated in the root window's colormap. Those allocations are preserved if necessary usingSetCloseDownMode('RetainPermanent')and an ID saved in the root window_XSETROOT_IDproperty. In this case the$Xconnection cannot be used any more as it could be killed at any time by anotherxsetrootfreeing the allocations. App::MathImage::X11::Protocol::XSetRoot->kill_id ($X)App::MathImage::X11::Protocol::XSetRoot->kill_id ($X, $rootwin)-
Kill any existing
_XSETROOT_IDon the given$rootwinXID. If$rootwinisundefor omitted then the$Xdefault root is used.This is normally only wanted when replacing
_XSETROOT_IDin the wayset_backgroundabove does.
SEE ALSO
HOME PAGE
http://user42.tuxfamily.org/math-image/index.html
LICENSE
Copyright 2010, 2011 Kevin Ryde
Math-Image is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version.
Math-Image is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with Math-Image. If not, see <http://www.gnu.org/licenses/>.