2005-01-03 06:40:20 +00:00
|
|
|
|
.TH PAGE 1
|
|
|
|
|
.SH NAME
|
2009-08-21 18:24:27 +00:00
|
|
|
|
page \- view
|
2005-01-03 06:40:20 +00:00
|
|
|
|
FAX,
|
|
|
|
|
image, graphic, PostScript, PDF, and
|
|
|
|
|
typesetter output
|
|
|
|
|
files
|
|
|
|
|
.SH SYNOPSIS
|
|
|
|
|
.B page
|
|
|
|
|
[
|
2009-08-21 18:24:27 +00:00
|
|
|
|
.B -abirPRvVw
|
|
|
|
|
]
|
|
|
|
|
[
|
|
|
|
|
.B -p
|
|
|
|
|
.I ppi
|
|
|
|
|
]
|
|
|
|
|
[
|
2005-01-03 06:40:20 +00:00
|
|
|
|
.IR file ...
|
|
|
|
|
]
|
2009-08-21 18:24:27 +00:00
|
|
|
|
.SH DESCRIPTION
|
|
|
|
|
.I Page
|
|
|
|
|
is a general purpose document viewer.
|
|
|
|
|
It can be used to display the individual pages
|
|
|
|
|
of a
|
|
|
|
|
PostScript,
|
|
|
|
|
PDF,
|
|
|
|
|
or
|
|
|
|
|
.IR troff (1)
|
|
|
|
|
or
|
|
|
|
|
Unix's \fItex\fR(1)
|
|
|
|
|
device-independent output
|
|
|
|
|
file.
|
|
|
|
|
.I Troff
|
|
|
|
|
or
|
|
|
|
|
.I tex
|
|
|
|
|
output is simply converted to PostScript in order to be viewed.
|
|
|
|
|
It can also be used to view any number of
|
|
|
|
|
graphics files
|
|
|
|
|
(such as a
|
|
|
|
|
FAX
|
|
|
|
|
page,
|
|
|
|
|
a Plan 9
|
|
|
|
|
.IR image (7)
|
|
|
|
|
file, an Inferno bitmap file, or other common format).
|
|
|
|
|
.I Page
|
|
|
|
|
displays these
|
|
|
|
|
in sequence.
|
|
|
|
|
In the absence of named files,
|
|
|
|
|
.I page
|
|
|
|
|
reads one from standard input.
|
2005-01-03 06:40:20 +00:00
|
|
|
|
.PP
|
2009-08-21 18:24:27 +00:00
|
|
|
|
By default,
|
|
|
|
|
.I page
|
|
|
|
|
runs in the window in which it is started
|
|
|
|
|
and leaves the window unchanged.
|
|
|
|
|
The
|
|
|
|
|
.B -R
|
|
|
|
|
option causes
|
|
|
|
|
.I page
|
|
|
|
|
to grow the window if necessary
|
|
|
|
|
to display the page being viewed.
|
|
|
|
|
The
|
|
|
|
|
.B -w
|
|
|
|
|
option causes
|
|
|
|
|
.I page
|
|
|
|
|
to create a new window for itself.
|
|
|
|
|
The newly created window will grow as under the
|
|
|
|
|
.B -R
|
|
|
|
|
option.
|
|
|
|
|
If being used to display
|
|
|
|
|
multipage documents,
|
|
|
|
|
only one file may be specified on the command line.
|
2005-01-03 06:40:20 +00:00
|
|
|
|
.PP
|
2009-08-21 18:24:27 +00:00
|
|
|
|
The
|
|
|
|
|
.B -p
|
|
|
|
|
option sets the resolution for PostScript and PDF
|
|
|
|
|
files, in pixels per inch.
|
|
|
|
|
The default is 100 ppi.
|
|
|
|
|
The
|
|
|
|
|
.B -r
|
|
|
|
|
option reverses the order in which pages are displayed.
|
2005-01-03 06:40:20 +00:00
|
|
|
|
.PP
|
2009-08-21 18:24:27 +00:00
|
|
|
|
When viewing a document,
|
2005-01-11 19:45:25 +00:00
|
|
|
|
.I page
|
2009-08-21 18:24:27 +00:00
|
|
|
|
will try to guess the true bounding box, usually rounding up from
|
|
|
|
|
the file's bounding box to
|
|
|
|
|
8½×11 or A4 size.
|
|
|
|
|
The
|
|
|
|
|
.B -b
|
|
|
|
|
option causes it to respect the bounding box given in the file.
|
|
|
|
|
As a more general problem,
|
|
|
|
|
some PostScript files claim to conform to Adobe's
|
|
|
|
|
Document Structuring Conventions but do not.
|
|
|
|
|
The
|
|
|
|
|
.B -P
|
|
|
|
|
option enables a slightly slower and slightly more
|
|
|
|
|
skeptical version of the PostScript processing code.
|
|
|
|
|
Unfortunately, there are PostScript documents
|
|
|
|
|
that can only be viewed with the
|
|
|
|
|
.B -P
|
|
|
|
|
option, and there are PostScript documents that
|
|
|
|
|
can only be viewed without it.
|
|
|
|
|
.PP
|
|
|
|
|
When viewing images with
|
|
|
|
|
.IR page ,
|
|
|
|
|
it listens to the
|
|
|
|
|
.B image
|
|
|
|
|
plumbing channel
|
|
|
|
|
(see
|
|
|
|
|
.IR plumber (4))
|
|
|
|
|
for more images to display.
|
|
|
|
|
The
|
|
|
|
|
.B -i
|
|
|
|
|
option causes
|
|
|
|
|
.I page
|
|
|
|
|
to not load any graphics files nor to read
|
|
|
|
|
from standard input but rather to listen
|
|
|
|
|
for ones to load from the plumbing channel.
|
|
|
|
|
.PP
|
|
|
|
|
The
|
|
|
|
|
.B -v
|
|
|
|
|
option turns on extra debugging output, and
|
|
|
|
|
the
|
|
|
|
|
.B -V
|
|
|
|
|
option turns on even more debugging output.
|
|
|
|
|
The
|
|
|
|
|
.B -a
|
|
|
|
|
option causes
|
2005-01-11 19:45:25 +00:00
|
|
|
|
.I page
|
2009-08-21 18:24:27 +00:00
|
|
|
|
to call
|
|
|
|
|
Unix's \fIabort\fR(3)
|
|
|
|
|
rather than exit cleanly on errors,
|
|
|
|
|
to facilitate debugging.
|
|
|
|
|
.PP
|
|
|
|
|
Pressing and holding button 1 permits panning about the page.
|
|
|
|
|
.PP
|
|
|
|
|
Button 2 raises a menu of operations on the current image or the
|
|
|
|
|
entire set. The image transformations are non-destructive and are
|
|
|
|
|
valid only for the currently displayed image. They are lost as soon
|
|
|
|
|
as another image is displayed.
|
|
|
|
|
The button 2 menu operations are:
|
|
|
|
|
.TF Resize
|
|
|
|
|
.TP
|
|
|
|
|
.B Orig size
|
|
|
|
|
Restores the image to the original. All modifications are lost.
|
|
|
|
|
.TP
|
|
|
|
|
.B Zoom
|
|
|
|
|
Prompts the user to sweep a rectangle on the image which is
|
|
|
|
|
expanded proportionally to the rectangle.
|
|
|
|
|
.TP
|
|
|
|
|
.B Fit window
|
|
|
|
|
Resizes the image so that it fits in the current window.
|
|
|
|
|
.TP
|
|
|
|
|
.B Rotate 90
|
|
|
|
|
Rotates the image 90 degrees clockwise
|
|
|
|
|
.TP
|
|
|
|
|
.B Upside down
|
|
|
|
|
Toggles whether images are displayed upside-down.
|
|
|
|
|
.TP
|
|
|
|
|
.B Next
|
|
|
|
|
Displays the next page.
|
|
|
|
|
.TP
|
|
|
|
|
.B Prev
|
|
|
|
|
Displays the previous page.
|
|
|
|
|
.TP
|
|
|
|
|
.B Zerox
|
|
|
|
|
Displays the current image in a new page window.
|
|
|
|
|
Useful for selecting important pages from large documents.
|
|
|
|
|
.TP
|
|
|
|
|
.B Reverse
|
|
|
|
|
Reverses the order in which pages are displayed.
|
|
|
|
|
.TP
|
|
|
|
|
.B Write
|
|
|
|
|
Writes the image to file.
|
|
|
|
|
.PD
|
|
|
|
|
.PP
|
|
|
|
|
Button 3 raises a menu of the
|
|
|
|
|
pages
|
|
|
|
|
to be selected for viewing in any order.
|
2005-01-03 06:40:20 +00:00
|
|
|
|
.PP
|
2009-08-21 18:24:27 +00:00
|
|
|
|
Typing a
|
|
|
|
|
.B q
|
|
|
|
|
or
|
|
|
|
|
control-D exits the program.
|
|
|
|
|
Typing a
|
|
|
|
|
.B u
|
|
|
|
|
toggles whether images are displayed upside-down.
|
|
|
|
|
(This is useful in the common case of mistransmitted upside-down faxes).
|
|
|
|
|
Typing a
|
|
|
|
|
.B r
|
|
|
|
|
reverses the order in which pages are displayed.
|
|
|
|
|
Typing a
|
|
|
|
|
.B w
|
|
|
|
|
will write the currently viewed page to a new file as a compressed
|
|
|
|
|
.IR image (7)
|
|
|
|
|
file.
|
|
|
|
|
When possible, the filename is of the form
|
|
|
|
|
.IR basename . pagenum . bit .
|
|
|
|
|
Typing a
|
|
|
|
|
.B d
|
|
|
|
|
removes an image from the working set.
|
2005-01-03 06:40:20 +00:00
|
|
|
|
.PP
|
2009-08-21 18:24:27 +00:00
|
|
|
|
To go to a specific page, one can type its number followed by enter.
|
|
|
|
|
Typing left arrow, backspace, or minus displays the previous page.
|
|
|
|
|
Typing right arrow, space, or enter displays the next page.
|
|
|
|
|
The up and down arrow pan up and down one half screen height,
|
|
|
|
|
changing pages when panning off the top or bottom of the page.
|
2005-01-03 06:40:20 +00:00
|
|
|
|
.PP
|
2009-08-21 18:24:27 +00:00
|
|
|
|
.I Page
|
|
|
|
|
calls
|
|
|
|
|
Unix's \fIgs\fR(1)
|
|
|
|
|
to draw each page of PostScript
|
|
|
|
|
and
|
|
|
|
|
PDF
|
|
|
|
|
.IR files .
|
|
|
|
|
It also calls a variety of conversion programs, such as those described in
|
|
|
|
|
.IR jpg (1),
|
|
|
|
|
to convert the various raster graphics formats
|
|
|
|
|
into Inferno bitmap files.
|
|
|
|
|
Pages are converted ``on the fly,'' as needed.
|
|
|
|
|
.SH EXAMPLES
|
|
|
|
|
.TP
|
|
|
|
|
.L
|
|
|
|
|
page /sys/src/cmd/gs/examples/tiger.eps
|
|
|
|
|
Display a color PostScript file.
|
|
|
|
|
.TP
|
|
|
|
|
.L
|
|
|
|
|
page /usr/inferno/icons/*.bit
|
|
|
|
|
Browse the Inferno bitmap library.
|
|
|
|
|
.TP
|
|
|
|
|
.L
|
|
|
|
|
man -t page | page -w
|
|
|
|
|
Preview this manual in a new window.
|
2005-01-03 06:40:20 +00:00
|
|
|
|
.SH "SEE ALSO
|
|
|
|
|
.IR gs (1),
|
|
|
|
|
.IR jpg (1),
|
|
|
|
|
.IR proof (1),
|
|
|
|
|
.IR tex (1),
|
|
|
|
|
.IR troff (1)
|
|
|
|
|
.SH SOURCE
|
2009-08-21 18:24:27 +00:00
|
|
|
|
.B \*9/src/cmd/page
|
|
|
|
|
.SH DIAGNOSTICS
|
|
|
|
|
The mouse cursor changes to an arrow and ellipsis
|
|
|
|
|
when
|
|
|
|
|
.I page
|
|
|
|
|
is reading or writing a file.
|
2005-01-11 19:45:25 +00:00
|
|
|
|
.SH BUGS
|
2009-08-21 18:24:27 +00:00
|
|
|
|
.I Page
|
|
|
|
|
supports reading of only one document
|
|
|
|
|
file at a time, and
|
|
|
|
|
the user interface is clumsy when viewing very large documents.
|
|
|
|
|
.PP
|
|
|
|
|
When viewing multipage PostScript files that do not contain
|
|
|
|
|
.RB `` %%Page ''
|
|
|
|
|
comments, the button 3 menu only contains
|
|
|
|
|
``this page'' and ``next page'':
|
|
|
|
|
correctly determining
|
|
|
|
|
page boundaries in Postscript code is not computable
|
|
|
|
|
in the general case.
|
|
|
|
|
.PP
|
|
|
|
|
If
|
2005-01-11 19:45:25 +00:00
|
|
|
|
.I page
|
2009-08-21 18:24:27 +00:00
|
|
|
|
has trouble viewing a Postscript file,
|
|
|
|
|
it might not be exactly conforming: try viewing it with the
|
|
|
|
|
.B -P
|
|
|
|
|
option.
|
2005-01-13 04:49:19 +00:00
|
|
|
|
.PP
|
2009-08-21 18:24:27 +00:00
|
|
|
|
The interface to the plumber is unsatisfactory. In particular,
|
|
|
|
|
document references cannot be sent
|
|
|
|
|
via plumbing messages.
|
|
|
|
|
.PP
|
|
|
|
|
There are too many keyboard commands and menu items.
|
2011-10-31 13:31:13 +00:00
|
|
|
|
.PP
|
|
|
|
|
Displaying a PostScript or PDF file depends both on having
|
|
|
|
|
GhostScript
|
|
|
|
|
(see
|
|
|
|
|
.IR gs (1))
|
|
|
|
|
installed and on the underlying operating system
|
|
|
|
|
providing a file descriptor device tree at
|
|
|
|
|
.BR /dev/fd .
|
|
|
|
|
.PP
|
|
|
|
|
Some FreeBSD installations
|
|
|
|
|
do not provide file descriptors greater than 2
|
|
|
|
|
in
|
|
|
|
|
.BR /dev/fd .
|
|
|
|
|
To fix this, add
|
|
|
|
|
.IP
|
|
|
|
|
.EX
|
|
|
|
|
/fdescfs /dev/fd fdescfs rw 0 0
|
|
|
|
|
.EE
|
|
|
|
|
.LP
|
|
|
|
|
to
|
|
|
|
|
.BR /etc/fstab ,
|
|
|
|
|
and then
|
|
|
|
|
.B mount
|
|
|
|
|
.BR /dev/fd .
|
|
|
|
|
(Adding the line to
|
|
|
|
|
.B fstab
|
|
|
|
|
ensures causes FreeBSD to mount the file system
|
|
|
|
|
automatically at boot time.)
|