Linux Commands Examples

A great documentation place for Linux commands

xwd

dump an image of an X window


see also : xwud - X

Synopsis

xwd [-debug] [-help] [-nobdrs] [-out file] [-xy] [-frame] [-add value] [-root | -id id | -name name ] [-icmap] [-screen] [-silent] [-display display]


add an example, a script, a trick and tips

: email address (won't be displayed)
: name

Step 2

Thanks for this example ! - It will be moderated and published shortly.

Feel free to post other examples
Oops ! There is a tiny cockup. A damn 404 cockup. Please contact the loosy team who maintains and develops this wonderful site by clicking in the mighty feedback button on the side of the page. Say what happened. Thanks!

examples

1
source
            
DISPLAY=:0 XAUTHORITY=/var/run/lightdm/root/$DISPLAY xwd -root > /tmp/screenshot.xwd
convert /tmp/screenshot.xwd /home/pi/screenly/static/img/screenshot.png
1
source
            
/usr/bin/xwd -root -out file.xwd
convert file.xwd current.jpg
cp current.jpg app/static
0
source
            
path=/home/vovka/Ã?þñÑ?ðöõýýÑÂ/screenshots/daily_screenshots/
xwd_file=/tmp/$file_name.xwd
target_file=$path$file_name.$file_extension
xwd -display :0 -root > $xwd_file
xwd -display :0 -root > $xwd_file
/usr/bin/convert $xwd_file $target_file
rm -f $xwd_file
0
source
            
TMPDIR=~/tmp
xwd $* >$TMPDIR/$DATE.xwd
convert $TMPDIR/$DATE.xwd $DESTFILE
PUBURL=`dropbox puburl $DESTFILE`
0
source
            
/usr/bin/xwd -root -out file.xwd
convert file.xwd current.jpg
cp current.jpg ./app/static
0
source
            
/usr/bin/xwd -root -out file.xwd
convert file.xwd current.jpg
convert current.jpg -resize 320 mini.jpg
cp current.jpg ./app/static
0
source
            
export DISPLAY=:0
xwd -root -out /home/icmc/taboca-telasocial/images/xwdss.xwd
convert /home/icmc/taboca-telasocial/images/xwdss.xwd /home/icmc/taboca-telasocial/images/test.png
convert /home/icmc/taboca-telasocial/images/xwdss.xwd /home/icmc/taboca-telasocial/images/test.png

description

Xwd is an X Window System window dumping utility. Xwd allows X users to store window images in a specially formatted dump file. This file can then be read by various other X utilities for redisplay, printing, editing, formatting, archiving, image processing, etc. The target window is selected by clicking the pointer in the desired window. The keyboard bell is rung once at the beginning of the dump and twice when the dump is completed.

options

-display display

This argument allows you to specify the server to connect to; see X(7).

-help

Print out the ’Usage:’ command syntax summary.

-nobdrs

This argument specifies that the window dump should not include the pixels that compose the X window border. This is useful in situations where you may wish to include the window contents in a document as an illustration.

-out file

This argument allows the user to explicitly specify the output file on the command line. The default is to output to standard out.

-xy

This option applies to color displays only. It selects ’XY’ format dumping instead of the default ’Z’ format.

-add value

This option specifies an signed value to be added to every pixel.

-frame

This option indicates that the window manager frame should be included when manually selecting a window.

-root

This option indicates that the root window should be selected for the window dump, without requiring the user to select a window with the pointer.

-id id

This option indicates that the window with the specified resource id should be selected for the window dump, without requiring the user to select a window with the pointer.

-name name

This option indicates that the window with the specified WM_NAME property should be selected for the window dump, without requiring the user to select a window with the pointer.

-icmap

Normally the colormap of the chosen window is used to obtain RGB values. This option forces the first installed colormap of the screen to be used instead.

-screen

This option indicates that the GetImage request used to obtain the image should be done on the root window, rather than directly on the specified window. In this way, you can obtain pieces of other windows that overlap the specified window, and more importantly, you can capture menus or other popups that are independent windows but appear over the specified window.

-silent

Operate silently, i.e. don’t ring any bells before and after dumping the window.

display

To get default host and display number.

environment

files

XWDFile.h

X Window Dump File format definition file.


see also

xwud , X


authors

Tony Della Fera, Digital Equipment Corp., MIT Project Athena
William F. Wyatt, Smithsonian Astrophysical Observatory

How can this site be more helpful to YOU ?


give  feedback