Date: Wed, 5 Dec 2001 20:00:01 -0500
Subject: MacOSX-TeX Digest #173 - 12/05/01
From: "TeX on Mac OS X Mailing List" 
To: "TeX on Mac OS X Mailing List" 
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-transfer-encoding: quoted-printable
Sender: 
Precedence: Bulk
List-Software: LetterRip Pro 3.0.7 by Fog City Software, Inc.
List-Subscribe: 
List-Digest: 
List-Unsubscribe: 

MacOSX-TeX Digest #173 - Wednesday, December 5, 2001

  TEX -> EPDF?
          by "Nick Matsakis" 
  Re: paths
          by "David R. Morrison" 
  Re: [Mac OS X TeX] TEX -> EPDF?
          by "William Adams" 
  Re: [Mac OS X TeX] TEX -> EPDF?
          by "Ross Moore" 
  Re: [Mac OS X TeX] TEX -> EPDF?
          by "Claus Gerhardt" 


----------------------------------------------------------------------

Subject: TEX -> EPDF?
From: "Nick Matsakis" 
Date: Wed, 5 Dec 2001 17:54:49 -0500 (EST)


So, I'm curious whether anyone knows a good way to get a single TeX
equation as a piece of embedded PDF?  I'm envisioning a package that works
like this:

\usepackage{pdfout}
\include{allmywackytexmacros.tex}

\begin{document}

\begin{pdfout}{exp1.pdf}
\[ 1+1 =3D 2 \]
\end{pdfout}

\begin{pdfout}{exp2.pdf}
\[ A =3D \pi \cdot r^2\]
\end{pdfout}

\end{document}

Running pdftex on the output would create two files in the directory,
exp1.pdf and exp2.pdf, each containing the appropriate equations.  Does
this make sense?  This would be useful because the resulting files could
be dragged into Omnigraffle or Powerpoint X, allowing one to have nicely
typeset equations in posters and presentations.

Nick



----------------------------------------------------------------------

Subject: Re: paths
From: "David R. Morrison" 
Date: Wed, 5 Dec 2001 17:55:48 -0500

Gerben Wierda writes:

> As far as I know, the only distribution that has ever conflicted with my =

> distribution is fink, because it forces itself at the start of the path.

And as pointed out in the previous message, the latest version of fink no
longer does this, because it inserts 
  
   /usr/local/teTeX/bin/powerpc-apple-darwin-current

prior to the fink paths (when the system-tetex fink package is installed).

  -- Dave



----------------------------------------------------------------------

Subject: Re: [Mac OS X TeX] TEX -> EPDF?
From: "William Adams" 
Date: Wed, 05 Dec 2001 18:08:08 -0500

matsakis said:
>So, I'm curious whether anyone knows a good way to get a single TeX
>equation as a piece of embedded PDF?

 work-around manual method.

Right problem, wrong solution.

What one wants is for TeXShop.app to provide a Service, ``TeX eq ->
EPDF'', so that one could then, within OmniGraffle, type  the desired
equation (say \magstep2$1+1=3D2$), select it, choose the Service and then
get in situ the ``epdf''---that's how it works in NeXTstep, and I can't
think of a more efficient fashion to get this sort of thing done....

And that's how I get
>...nicely
>typeset equations in posters and presentations.

on my NeXT Cube at home....

William

--
William Adams, publishing specialist
ATLIS Graphics & Design / 717-731-6707 voice / 717-731-6708 fax
Sphinx of black quartz, judge my vow.
http://www.atlis.com



----------------------------------------------------------------------

Subject: Re: [Mac OS X TeX] TEX -> EPDF?
From: "Ross Moore" 
Date: Thu, 6 Dec 2001 10:53:58 +1100 (EST)

> matsakis said:
> >So, I'm curious whether anyone knows a good way to get a single TeX
> >equation as a piece of embedded PDF?
> 
>  work-around manual method.
> 
> Right problem, wrong solution.
> 
> What one wants is for TeXShop.app to provide a Service, ``TeX eq ->
> EPDF'', so that one could then, within OmniGraffle, type  the desired
> equation (say \magstep2$1+1=3D2$), select it, choose the Service and =
then
> get in situ the ``epdf''---that's how it works in NeXTstep, and I can't
> think of a more efficient fashion to get this sort of thing done....
> 
> And that's how I get
> >...nicely
> >typeset equations in posters and presentations.

There is no need to have the equations in different PDF documents.
It is surely sufficient to have TeX typeset them as separate
pages in the same document.
The cute part is to make the bounding-box (or MediaBox) fit
the contents, for each page.

Then you have a nice collection, from which you can easily
extract the image that you need for some other purpose.



In fact this is very easy to do, using TeX's \shipout primitive.

  \shipout\hbox{...contents...}

or

  \shipout\vbox{...contents...}

will do essentially what you want ...


	... however, you have to take margins and offsets
into account, else these may be added "behind the scenes".
So it's better to do a bit of other processing first.


I have several examples of exactly this kind of thing, at:

   http://www-texdev.ics.mq.edu.au/WARM/WARMhome/ILLUS902/

in files named  testimage.pdf   with  from 1 to 8 .
Look at the *last* page of each document.

Indeed, I showed the results of the `Encapsulated PDF' technique
at TUG2001, in one of my talks.


The source code for the above examples is available as   =
testimage.tex  .

It contains code such as:

  \newbox\shipoutbox

  \global\setbox\shipoutbox=3D\hbox{.... contents ... }

 \newpage\parindent=3D0pt \leftmargin0pt
 \setbox0=3D\vbox{\kern -1truein
   \hbox{\kern -1truein 
    \framebox{\box\shipoutbox }%
    \kern 1truein}%
   \kern1truein}%
 \ifx\undefined\pdfoutput\else
  \dimen0\ht0 \advance\dimen0\dp0
  \pdfpageheight\dimen0
  \pdfpagewidth\wd0
 \fi
 \shipout\box0


Note the need to set the  \pdfpageheight  and  \pdfpagewidth
before shipping-out; and the need to  \kern-1truein  to
compensate for the location of the top-left corner of a page.


BTW, for the true setting of those example documents,
visit   http://www-texdev.ics.mq.edu.au/WARM/
and scroll down to the link to   PDF-LaTeX examples.



Hope this helps,

	Ross Moore


 
> on my NeXT Cube at home....

This `Encapsulated PDF' technique is already at your finger-tips.  :-)

 
> William
> 
> --
> William Adams, publishing specialist
> ATLIS Graphics & Design / 717-731-6707 voice / 717-731-6708 fax
> Sphinx of black quartz, judge my vow.
> http://www.atlis.com
> 
> 
> 
> -----------------------------------------------------------------
> To UNSUBSCRIBE, send email to  with
> "unsubscribe macosx-tex" (no quotes) in the body.
> For additional HELP, send email to  with
> "help" (no quotes) in the body.
> This list is not moderated, and I am not responsible for
> messages posted by third parties.
> -----------------------------------------------------------------


----------------------------------------------------------------------

Subject: Re: [Mac OS X TeX] TEX -> EPDF?
From: "Claus Gerhardt" 
Date: Thu, 6 Dec 2001 01:28:35 +0100

--=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D_-1204523952=3D=3D_ma=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D
Content-Type: text/plain; charset=3D"iso-8859-1" ; format=3D"flowed"
Content-Transfer-Encoding: quoted-printable

>So, I'm curious whether anyone knows a good way to get a single TeX
>equation as a piece of embedded PDF?  I'm envisioning a package that =
works
>like this:
>
>\usepackage{pdfout}
>\include{allmywackytexmacros.tex}
>
>\begin{document}
>
>\begin{pdfout}{exp1.pdf}
>\[ 1+1 =3D3D 2 \]
>\end{pdfout}
>
>\begin{pdfout}{exp2.pdf}
>\[ A =3D3D \pi \cdot r^2\]
>\end{pdfout}
>
\end{document}

My solution to the problem is to use the package mfpic with the 
option metapost. Below is a complete latex source file for a formula.

\documentclass[a4paper]{article}
\usepackage[metapost]{mfpic}
\opengraphsfile{myname}

\begin{document}

\begin{mfpic}[20]{0}{4}{0}{4}
%the numbers are arbitrary but reasonable in the present context.


\tlabel(0,0){ $\int_a^b=3D3Df(x) dx$ }


\end{mfpic}

\closegraphsfile
\end{document}

After the first run of the document a file myname.mp is created which 
one has to transform via the terminal using the command

mpost myname

After the second run of the document the file myname.pdf contains the 
formula. One can then open this file with Adobe Illustrator and save 
it as an .eps file.


Claus
>


-- 


Claus Gerhardt
Institut f=3DFCr Angewandte Mathematik
Ruprecht-Karls-Universit=3DE4t Heidelberg
Im Neuenheimer Feld 294
69120 Heidelberg
Germany

Homepage: http://www.math.uni-heidelberg.de/studinfo/gerhardt/
--=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D_-1204523952=3D=3D_ma=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D
Content-Type: text/html; charset=3D"iso-8859-1"
Content-Transfer-Encoding: quoted-printable


Re: [Mac OS X TeX] TEX ->
EPDF?
So, I'm curious whether anyone knows a good way to get a single TeX
equation as a piece of embedded PDF?  I'm envisioning a package that works
like this:

\usepackage{pdfout}
\include{allmywackytexmacros.tex}

\begin{document}

\begin{pdfout}{exp1.pdf}
\[ 1+1 =3D3D 2 \]
\end{pdfout}

\begin{pdfout}{exp2.pdf}
\[ A =3D3D \pi \cdot r^2\]
\end{pdfout}
\end{document}

My solution to the problem is to use the package mfpic with the option metapost. Below is a complete latex source file for a formula.

\documentclass[a4paper]{article}
\usepackage[metapost]{mfpic}
\opengraphsfile{myname}

\begin{document}
\begin{mfpic}[20]{0}{4}{0}{4}
%the numbers are arbitrary but reasonable in the present context.


\tlabel(0,0){ $\int_a^b=3D3Df(x) dx$ }

\end{mfpic}

\closegraphsfile
\end{document}
After the first run of the document a file myname.mp is created which one has to transform via the terminal using the command

mpost myname

After the second run of the document the file myname.pdf contains the formula. One can then open this file with Adobe Illustrator and save it as an .eps file.


Claus



-- 


Claus Gerhardt
Institut f=3DFCr Angewandte Mathematik
Ruprecht-Karls-Universit=3DE4t Heidelberg
Im Neuenheimer Feld 294
69120 Heidelberg
Germany

Homepage: http://www.math.uni-heidelberg.de/studinfo/gerhardt/
--=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D_-1204523952=3D=3D_ma=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D-- ---------------------------------------------------------------------- End of MacOSX-TeX Digest ----------------------------------------------------------------- To UNSUBSCRIBE, send email to with "unsubscribe macosx-tex" (no quotes) in the body. For additional HELP, send email to with "help" (no quotes) in the body. This list is not moderated, and I am not responsible for messages posted by third parties. -----------------------------------------------------------------