I want to trim the main area of a file PSor PDFto create a file EPSwithout a space. Team ghostrcipt, ps2pdf, epstoolscan cut the main drawing of the document file.
The problem is that they are only cropped in their original form, but I want to create an EPS file with BoundingBox 0 0 x y; cropped and moved to the lower left corner.
The difference is i, when we want to insert the resulting EPS file inside the PS document. When BoundingBox x0 y0 x y, a PS document inserts an EPS file at x0 y0 instead of where we are.
Example:
Consider a simple file PSas
%!
/Times-Roman findfont
11 scalefont setfont
72 700 moveto
(This is a test)show
if you convert it to EPSusing a command like
ps2eps test.ps test.eps
He will produce
%!PS-Adobe-2.0 EPSF-2.0
%%BoundingBox: 72 700 127 708
%%HiResBoundingBox: 72.000000 700.000000 127.000000 707.500000
%%EndComments
% EPSF created by ps2eps 1.68
%%BeginProlog
save
countdictstack
mark
newpath
/showpage {} def
/setpagedevice {pop} def
%%EndProlog
%%Page 1 1
/Times-Roman findfont
11 scalefont setfont
72 700 moveto
(This is a test)show
%%Trailer
cleartomark
countdictstack
exch sub { end } repeat
restore
%%EOF
, BoundingBox 72 700 127 708. , EPS PS, .
EPS BoundingBox: 0 0 55 8. , ( moveto) .
.. , - BoundingBox, PS. , : EPS PS BoundingBox.
, EPS 200 200 255 208 PS. EPS , , BoundingBox 0 0:
200 200 translate
save
/showpage {} bind def
(test.eps)run
restore