SDUMP
Home ›
Software ›
Manual Pages ›
SDUMP
Section: User Commands (1)
Updated:
Index
Return to Main Contents
NAME
sdump, sdumpopt - graphics terminal screen dump
SYNOPSIS
sdump
[options]
[lp-options]
[file] ...
sdumpopt
[options]
DESCRIPTION
Sdump
takes a copy of the screen of a graphics terminal
(or more typically the window from which it is run)
and prints it out on a printer.
Normally, screen dumps are produced in a one step process:
after having made a copy of the screen's current contents,
sdump
automatically calls
lp(1)
or
lpr(1)
to perform the printing in the background.
Screen dumps can also be handled using a two step process.
Using the
-save
fname
option, you can get
sdump
to save a copy of the screen into the specified file
fname,
using the image file format described in
gpsras(5).
Later, you can invoke
sdump,
giving it one or more
file
arguments;
it will print these saved screen images on one page.
The file name
-
stands for the standard input,
and may be given along with other file names.
If no file names are given, the standard input is
not
assumed.
Rather, without file name arguments,
sdump
will grab a screen image and print it or save it.
Sdumpopt
allows you to change the default actions taken by
sdump
when certain options are omitted from its command line.
The options you give to
sdumpopt
are saved in the file
.sdumprc
in your home directory.
Sdump
looks at this file to get its default options.
You can view your current defaults by invoking
sdumpopt
with no arguments.
The options recognised by both commands are:
- -res dpi
-
Print the image at a resolution of
dpi
dots/inch.
Affects only the printing phase.
Values allowed are device dependent.
For the HP LaserJet, they are 300, 150 (the initial default), 100, and 75.
- -rot deg
-
Rotate the image counter-clockwise by
deg
degrees.
Affects only the printing phase.
Values allowed are device dependent.
For the HP LaserJet, they are 0, 90, 180, and 270
(or -90, the initial default).
- -inv
-
Print an "inverse video" image.
Dark dots on screen print as black dots, with the assumption being made that
the image is drawn using dark colours on a light or white background.
Historically, this was known as inverse or reverse video, because the norm used
to be white on black..
This option is normally on by default.
Affects only the printing phase.
- -noinv
-
Print a positive image.
I.e. disable
-inv
option, for cases where the image on screen is white on black, and you want
the white parts printed black..
Affects only the printing phase.
- -lines n
-
Grab
n
raster scan lines from the screen or window.
Initially, the entire screen or window is grabbed.
This option historically allowed you to eliminate the bottom few lines.
It is currently ignored on X Window based systems.
- -save fname
-
Save the screen image in the named file, rather than automatically
printing it.
By default, the image is saved in
gpsras(5)
format, for later printing by the sdump command.
However, you can append any of these file name suffixes to
fname
to get the file saved in the corresponding format:
.gif,
.tif
(or
.tiff),
.jpg
(or
.jpeg),
.ppm,
.pbm,
.png,
.pdf,
.eps
(or
.ps),
.bmp,
.xpm
or
.xbm.
Of all of these,
.png
is probably the best choice to get a reasonably compact file with the least
chance of losing image detail or colour.
For these file formats, you will not be able to print out the saved image
files directly using the sdump command, but you can easily use them to import
images into other programs.
You can also specify the reserved file name
.psprinter,
which will cause
sdump
to print out the screen dump to a PostScript printer.
This allows printouts of color or grayscale screen dumps, rather than the
default black on white printouts normally produced, but it is limited to
PostScript compatible printers.
(On most Linux systems and Mac OS X 10.3 and up, all supported printers are
essentially PostScript compatible because the printing system emulates
PostScript for non-PS printers.)
- -nosave
-
Disable the
-save
option, and automatically print the screen image.
Any other option arguments to
sdump
are passed along to
lp.
If you use the
-save
option with
sdumpopt,
sdump
will not write all screen images to the same file by default.
Rather, it will "increment" the file name saved in
.sdumprc,
so that the next screen image goes to a new file.
Although
sdump
can be invoked directly as a UNIX command, it is often invoked
automatically when a screen dump request is received by programs such
as
analysis,
frmsel,
peel,
raster,
and
wtsum.
A screen dump is requested in these programs by pressing the
quit
key, normally
Control-B,
or by selecting
Plot/Video
or
Hardcopy/Video ,
when available,
from the programs' menus.
When invoked in this way,
sdump
is not given any options or file name arguments.
Its options can be changed via
sdumpopt.
The printing of
gpsras(5)
format image files is handled by the
lp
interface program for the default printer,
or by the filter set up by
selectlp(1)
on
lpr
based systems.
EXAMPLES
The commands below illustrate the use of the
-save
option:
-
sdumopt -save screen1 -lines 600
sdump
sdump -save dumpfile
sdump -lines 560
sdump -res 300 -rot 0 dumpfile screen*
sdumpopt
The first command sets up
.sdumprc
in your home directory.
The second command saves the screen image in the file
screen1,
and increments the file name stored in
.sdumprc.
The third command saves the screen image in
dumpfile,
and doesn't change the file name stored in
.sdumprc.
The fourth command saves the top 560 lines of the screen image in the
file
screen2.
The fifth command prints the saved images at 300 DPI,
in the given order, on one page in portrait orientation.
The last command shows the current options, which should include
"-save screen3 -lines 600."
X WINDOW SUPPORT
When the X Window version of this program is run on an X Window terminal,
it will grab the image of the window selected by the
WINDOWID
environment variable.
All the X Window versions of programs in this package set this variable
when they create a window, as does the
xterm
program.
Unlike the other X Window programs in this package,
sdump
will not recognise the usual X command line options,
such as
-display.
(The environment variable for setting this option will work, however.)
FILES
~/.sdumprc user defaults
SEE ALSO
gpsras(5),
analysis(1), frmsel(1), peel(1), raster(1), wtsum(1)
BUGS
Sdump
saves or prints only black and white images.
Images from a colour display are converted to black and white
by the
xpr
utility, which maps all light colours to white and dark colours to black.
This may not be quite what you expect if some of the colours drawn on the
background of your window are a bit on the light side.
Index
- NAME
-
- SYNOPSIS
-
- DESCRIPTION
-
- EXAMPLES
-
- X WINDOW SUPPORT
-
- FILES
-
- SEE ALSO
-
- BUGS
-
This document was created by
man2html,
using the manual pages.
Time: 17:58:06 GMT, February 20, 2019
Copyright © G. R. Detillieux,
Spinal Cord Research Centre,
The University of Manitoba.