The DSC elementary type
(atend)
may be used to defer bounding box
data to the end of the EPS file. This means an application may need to
parse through the
%%Trailer
comments to obtain the bounding box data.
3. If the version and bounding box comments are found, the application
should prompt the user to place the EPS file. It should then display the
screen preview. If no preview is provided with the EPS file, the application
must provide a representation of the EPS file.
If the application must create its own representation, a gray box matching
the extent of the bounding box with some information in it suffices. The
information should at least include the title of the EPS file. This can be
obtained from the DSC header comment:
%%Title:
. Other information,
such as
%%Creator:
and
%%Creation-Date:
, may also be displayed.
The bounding box comment can be used to help determine scaling factors
and the proportions of the illustration. The including application should
enable the user to specify a “placement box” to display the screen preview
or the application-supplied representation of the screen preview if there is
not a preview present in the EPS file.
The bounding box can be used to calculate a ratio that the application can
use if the user wants to maintain original proportions while specifying a
placement box. Alternately, the application may display the preview full size,
and then allow the user to size and place the graphic as desired. Regardless
of the method used to display the preview initially, the user should have the
option of maintaining the original proportions supplied by the bounding box
or distorting the proportions of the EPS graphic.
3.2
Producing a Composite PostScript Language Program
The following guidelines must be considered when producing a composite
PostScript language program that includes an imported EPS file.
Use
save
and
restore
An application should encapsulate the imported EPS file in a
save
/
restore
construct. This allows all VM the EPS file uses to be recovered and the graph-
ics state to be restored.
Redefine s
howpage
The
showpage
operator is permitted in EPS files because it is present in so
many PostScript language files. Therefore, it is reasonable for an EPS file to
use the
showpage
operator, although it is not necessary if the EPS file will
only be imported into another document. The application importing the EPS
file is responsible for redefining
showpage
.
showpage
may be redefined
using the following code segment:
14
(1 May 92)
Home Index Bookmark Pages
Pages: Home Index