[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: eps file without a bounding box

From: Ted Harding
Subject: RE: eps file without a bounding box
Date: Fri, 26 Nov 1999 10:39:02 -0000 (GMT)

On 26-Nov-99 Tamas Papp wrote:
> By the way, is there a way to give bounding boxes based on the size by
> an external utility? Gv displays the file correctly, as if it had a
> boundinc box.

The ghostscript utility 'ps2epsi' will take a PostScript file (not
containing BB information) and produce an "EPSI" file -- that is,
an EPS file which includes BoundingBox information, and also contains a
block of "comments" which are binary information allowing suitable
software (other than a PS interpreter; e.g. a WP package) to generate a

This latter stuff has no effect on a real PostScript interpreter and
simply occupies space; it could be worth hacking the PS code in the
'ps2epsi' driver file, which is 'ps2epsi.ps', to suppress it.

I have also found that 'ps2epsi' has a tendency to slightly clip
the edges of the graphic because of the fact that ghostscript
uses font metrics, for its non-kosher fonts, which are slightly different
from the real Adobe metrics: if, for instance, the bottom line is
text, you may find that the very bottom of some letters gets
clipped off when printed on a PS printer. My solution to this was, again,
to hack 'ps2epsi.ps' so as to very slightly enlarge the BoundingBox.

If you have software which claims to produce an EPS file and it
has no "%%BoundingBox: llz lly urx ury" line, then it's not doing its job.

Some software inserts near the beginning of the file a line

%%BoundingBox: atend

and then should, near the very end of the file, insert the true
BoundingBox line. I have encountered cases where software whose
job is to import an EPS file only finds the first, and then asserts
that it is not a valid BB line. I'm sure Lout doesn't do this ... !

Watch out also for the distinction between %%BoundingBox and
%%PageBoundingBox -- in a multipage document, the first is the boundary
for all marks on all pages; the second is local to each page on which
it occurs. Again, malfunctioning software could generate an "EPS" file
which included the second but not the first.

Hope this helps,

E-Mail: (Ted Harding) <address@hidden>
Date: 26-Nov-99                                       Time: 10:39:02
------------------------------ XFMail ------------------------------

reply via email to

[Prev in Thread] Current Thread [Next in Thread]