[OS X TeX] Including igures .ps
Bruno Voisin
Bruno.Voisin at hmg.inpg.fr
Thu Aug 29 05:21:56 EDT 2002
Le jeudi, 29 aoû 2002, à 10:05 Europe/Paris, Eva Pruneda a écrit :
> I work with Textures 2.1.
>
> I have a problem including .ps figures with
> \includegraphics. I can see the figure only when I print the
> document, not
> in my screen. Is a problem with the .ps or .eps files?, which is the
> correct
> waty to obtain this files?
>
> There is a .ps file in the textures documentation which has not
> problems,
> but I don't know what is the differences between this and my files.
The PostScript code in a .ps or .eps figure is only used for printing
the figure (actually it is a program telling the printer what to draw
and where). You can see this code, for example, by opening the .ps file
in a text editor like TextEdit, BBEdit or Alpha.
Now, .ps and .eps files created by Mac OS 9-compliant applications
include a PICT resource containing a version of the figure used for
screen preview. It is distinct from the PostScript code, and written in
a different language called QuickDraw.
In summary, the .ps figure in Textures' documentation contains two
parts:
- In the data fork (or part) of the file, the PostScript code used for
printing the figure. This code is just plain ASCII text.
- In the (hidden) resource fork (or part) of the file, the QuickDraw
code used for displaying the picture. This code is binary; its
existence is revealed, for example, by opening the file in ResEdit.
.ps files created by Unix programs generally include only the
PostScript code itself (resources are a Mac-specific concept). There
are two utilities (at least) on Mac for adding a preview resource to a
.ps file:
- PS2EPS+ at <http://www.lerup.com/ps2eps.shtml>.
- MacGhostViewX at <http://www.kiffe.com/cmactex.html>.
Both use internally the Unix program GhostScript to create the preview.
PS2EPS+ is based on an old version of GhostScript, so it might have
problem with recent .ps files.
That being said, on OS X you don't really need to do this: TeXShop, for
example, converts .ps files to .pdf files which are displayed directly
by OS X.
One more thing: what I said above about the two parts of Mac OS
9-compliant .ps files is an oversimplification:
- There are files containing a PS preview in the data fork itself, in
addition to the PS code used for printing.
- There are files in which the PS code used for printing is actually
contained and hidden in the PICT resource fork, in addition to the
QuickDraw preview code. These are the files called by Mathematica "PICT
with embedded PostScript" and by KaleidaGraph "PostScript PICT".
What a mess!
Bruno Voisin
-----------------------------------------------------------------
Threaded list archives can be found at:
<http://www.masda.vxu.se/~pku/MacOSX_TeX/>
-----------------------------------------------------------------
To UNSUBSCRIBE, send email to <info at email.esm.psu.edu> with
"unsubscribe macosx-tex" (no quotes) in the body.
For additional HELP, send email to <info at email.esm.psu.edu> with
"help" (no quotes) in the body.
-----------------------------------------------------------------
More information about the MacOSX-TeX
mailing list