Discussion:
[OS X TeX] How to plot functions with PGF and TeXShop ?
Franck Pastor
2006-01-15 10:44:30 UTC
Permalink
Hello,

I'm facing a strange problem with PGF (a package for drawings, by
Till Tantau, that I am currently testing) and TeXShop. This package
needs and calls Gnuplot to plot functions. To do this, you have to
call pdflatex with the option "shell-escape". Here is an example:

\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}[domain=0:4]
\draw[very thin,color=gray] (-0.1,-1.1) grid (3.9,3.9);
\draw[->] (-0.2,0) -- (4.2,0) node[right] {$x$};
\draw[->] (0,-1.2) -- (0,4.2) node[above] {$f(x)$};
\draw[color=red] plot[id=x] function{x} node[right] {$f(x) =x$};
\draw[color=blue] plot[id=sin] function{sin(x)} node[right] {$f(x) =
\sin x$};
\draw[color=orange] plot[id=exp] function{0.05*exp(x)} node[right] {$f
(x) = \frac{1}{20} \mathrm e^x$};
\end{tikzpicture}
\end{document}

If I name this program "pgf-test.tex", and if I enter in the Terminal:

pdflatex --shell-escape pgf-test.tex

everything works fine. But if I compile it with TeXShop (whose
preferences are set to "--shell-escape", of course), the functions
are not drawn ! And I can't understand why. It seems that TeXShop
can't find Gnuplot, which is installed in /sw/bin via Fink.

Any idea to help me understand this problem (and solve it if possible) ?

Thanks,

Franck Pastor
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Peter Lichtner
2006-01-15 17:30:25 UTC
Permalink
It worked fine for me with TeXShop---after I installed pgf in ~/
Library/texmf/tex/latex.
...Peter
Post by Franck Pastor
Hello,
I'm facing a strange problem with PGF (a package for drawings, by
Till Tantau, that I am currently testing) and TeXShop. This package
needs and calls Gnuplot to plot functions. To do this, you have to
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}[domain=0:4]
\draw[very thin,color=gray] (-0.1,-1.1) grid (3.9,3.9);
\draw[->] (-0.2,0) -- (4.2,0) node[right] {$x$};
\draw[->] (0,-1.2) -- (0,4.2) node[above] {$f(x)$};
\draw[color=red] plot[id=x] function{x} node[right] {$f(x) =x$};
\draw[color=blue] plot[id=sin] function{sin(x)} node[right] {$f(x)
= \sin x$};
\draw[color=orange] plot[id=exp] function{0.05*exp(x)} node[right]
{$f(x) = \frac{1}{20} \mathrm e^x$};
\end{tikzpicture}
\end{document}
pdflatex --shell-escape pgf-test.tex
everything works fine. But if I compile it with TeXShop (whose
preferences are set to "--shell-escape", of course), the functions
are not drawn ! And I can't understand why. It seems that TeXShop
can't find Gnuplot, which is installed in /sw/bin via Fink.
Any idea to help me understand this problem (and solve it if
possible) ?
Thanks,
Franck Pastor
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
<><><><><><><><><><><><><><><><><><><><><>
Peter C. Lichtner (***@lanl.gov)
LANL EES-6: MS D469
(505) 667-3420 (o)
(505) 665-3285 (fax)
Los Alamos National Laboratory
SM-30 Bikini Atoll Road
Los Alamos, NM 87545
<><><><><><><><><><><><><><><><><><><><><>



------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Franck Pastor
2006-01-15 17:37:37 UTC
Permalink
Same here...

Franck Pastor
Post by Peter Lichtner
It worked fine for me with TeXShop---after I installed pgf in ~/
Library/texmf/tex/latex.
...Peter
Post by Franck Pastor
Hello,
I'm facing a strange problem with PGF (a package for drawings, by
Till Tantau, that I am currently testing) and TeXShop. This
package needs and calls Gnuplot to plot functions. To do this, you
have to call pdflatex with the option "shell-escape". Here is an
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}[domain=0:4]
\draw[very thin,color=gray] (-0.1,-1.1) grid (3.9,3.9);
\draw[->] (-0.2,0) -- (4.2,0) node[right] {$x$};
\draw[->] (0,-1.2) -- (0,4.2) node[above] {$f(x)$};
\draw[color=red] plot[id=x] function{x} node[right] {$f(x) =x$};
\draw[color=blue] plot[id=sin] function{sin(x)} node[right] {$f(x)
= \sin x$};
\draw[color=orange] plot[id=exp] function{0.05*exp(x)} node[right]
{$f(x) = \frac{1}{20} \mathrm e^x$};
\end{tikzpicture}
\end{document}
If I name this program "pgf-test.tex", and if I enter in the
pdflatex --shell-escape pgf-test.tex
everything works fine. But if I compile it with TeXShop (whose
preferences are set to "--shell-escape", of course), the functions
are not drawn ! And I can't understand why. It seems that TeXShop
can't find Gnuplot, which is installed in /sw/bin via Fink.
Any idea to help me understand this problem (and solve it if
possible) ?
Thanks,
Franck Pastor
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
<><><><><><><><><><><><><><><><><><><><><>
LANL EES-6: MS D469
(505) 667-3420 (o)
(505) 665-3285 (fax)
Los Alamos National Laboratory
SM-30 Bikini Atoll Road
Los Alamos, NM 87545
<><><><><><><><><><><><><><><><><><><><><>
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Peter Lichtner
2006-01-15 17:45:53 UTC
Permalink
Sorry! I take that back---it only worked because I had first run from
the shell with pdflatex --shell-escape pgf-test.tex. Running TeXShop
in a 'clean' directory gives incorrect results with gnuplot not found:

loading : Context Support Macros / PDF (2004.03.26)
)sh: line 1: gnuplot: command not found
sh: line 1: gnuplot: command not found
sh: line 1: gnuplot: command not found

...Peter
Post by Peter Lichtner
It worked fine for me with TeXShop---after I installed pgf in ~/
Library/texmf/tex/latex.
...Peter
Post by Franck Pastor
Hello,
I'm facing a strange problem with PGF (a package for drawings, by
Till Tantau, that I am currently testing) and TeXShop. This
package needs and calls Gnuplot to plot functions. To do this, you
have to call pdflatex with the option "shell-escape". Here is an
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}[domain=0:4]
\draw[very thin,color=gray] (-0.1,-1.1) grid (3.9,3.9);
\draw[->] (-0.2,0) -- (4.2,0) node[right] {$x$};
\draw[->] (0,-1.2) -- (0,4.2) node[above] {$f(x)$};
\draw[color=red] plot[id=x] function{x} node[right] {$f(x) =x$};
\draw[color=blue] plot[id=sin] function{sin(x)} node[right] {$f(x)
= \sin x$};
\draw[color=orange] plot[id=exp] function{0.05*exp(x)} node[right]
{$f(x) = \frac{1}{20} \mathrm e^x$};
\end{tikzpicture}
\end{document}
If I name this program "pgf-test.tex", and if I enter in the
pdflatex --shell-escape pgf-test.tex
everything works fine. But if I compile it with TeXShop (whose
preferences are set to "--shell-escape", of course), the functions
are not drawn ! And I can't understand why. It seems that TeXShop
can't find Gnuplot, which is installed in /sw/bin via Fink.
Any idea to help me understand this problem (and solve it if
possible) ?
Thanks,
Franck Pastor
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
<><><><><><><><><><><><><><><><><><><><><>
LANL EES-6: MS D469
(505) 667-3420 (o)
(505) 665-3285 (fax)
Los Alamos National Laboratory
SM-30 Bikini Atoll Road
Los Alamos, NM 87545
<><><><><><><><><><><><><><><><><><><><><>
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
<><><><><><><><><><><><><><><><><><><><><>
Peter C. Lichtner (***@lanl.gov)
LANL EES-6: MS D469
(505) 667-3420 (o)
(505) 665-3285 (fax)
Los Alamos National Laboratory
SM-30 Bikini Atoll Road
Los Alamos, NM 87545
<><><><><><><><><><><><><><><><><><><><><>



------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Franck Pastor
2006-01-15 17:37:37 UTC
Permalink
I meant: same directory... and it doesn't work, anyway.

Franck Pastor
Post by Peter Lichtner
It worked fine for me with TeXShop---after I installed pgf in ~/
Library/texmf/tex/latex.
...Peter
Post by Franck Pastor
Hello,
I'm facing a strange problem with PGF (a package for drawings, by
Till Tantau, that I am currently testing) and TeXShop. This
package needs and calls Gnuplot to plot functions. To do this, you
have to call pdflatex with the option "shell-escape". Here is an
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}[domain=0:4]
\draw[very thin,color=gray] (-0.1,-1.1) grid (3.9,3.9);
\draw[->] (-0.2,0) -- (4.2,0) node[right] {$x$};
\draw[->] (0,-1.2) -- (0,4.2) node[above] {$f(x)$};
\draw[color=red] plot[id=x] function{x} node[right] {$f(x) =x$};
\draw[color=blue] plot[id=sin] function{sin(x)} node[right] {$f(x)
= \sin x$};
\draw[color=orange] plot[id=exp] function{0.05*exp(x)} node[right]
{$f(x) = \frac{1}{20} \mathrm e^x$};
\end{tikzpicture}
\end{document}
If I name this program "pgf-test.tex", and if I enter in the
pdflatex --shell-escape pgf-test.tex
everything works fine. But if I compile it with TeXShop (whose
preferences are set to "--shell-escape", of course), the functions
are not drawn ! And I can't understand why. It seems that TeXShop
can't find Gnuplot, which is installed in /sw/bin via Fink.
Any idea to help me understand this problem (and solve it if
possible) ?
Thanks,
Franck Pastor
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
<><><><><><><><><><><><><><><><><><><><><>
LANL EES-6: MS D469
(505) 667-3420 (o)
(505) 665-3285 (fax)
Los Alamos National Laboratory
SM-30 Bikini Atoll Road
Los Alamos, NM 87545
<><><><><><><><><><><><><><><><><><><><><>
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Herbert Schulz
2006-01-15 17:44:10 UTC
Permalink
Post by Franck Pastor
Hello,
I'm facing a strange problem with PGF (a package for drawings, by
Till Tantau, that I am currently testing) and TeXShop. This package
needs and calls Gnuplot to plot functions. To do this, you have to
...
Howdy,

Is there a recent binary distribution of Gnuplot for Mac OS X?

Good Luck,

Herb Schulz
(***@wideopenwest.com)


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Peter Lichtner
2006-01-15 17:46:34 UTC
Permalink
Best is to install gnuplot from fink.
...Peter
Post by Herbert Schulz
Post by Franck Pastor
Hello,
I'm facing a strange problem with PGF (a package for drawings, by
Till Tantau, that I am currently testing) and TeXShop. This
package needs and calls Gnuplot to plot functions. To do this, you
have to call pdflatex with the option "shell-escape". Here is an
...
Howdy,
Is there a recent binary distribution of Gnuplot for Mac OS X?
Good Luck,
Herb Schulz
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
<><><><><><><><><><><><><><><><><><><><><>
Peter C. Lichtner (***@lanl.gov)
LANL EES-6: MS D469
(505) 667-3420 (o)
(505) 665-3285 (fax)
Los Alamos National Laboratory
SM-30 Bikini Atoll Road
Los Alamos, NM 87545
<><><><><><><><><><><><><><><><><><><><><>



------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Franck Pastor
2006-01-15 17:49:39 UTC
Permalink
I agree, and that's what I did.

Franck
Post by Peter Lichtner
Best is to install gnuplot from fink.
...Peter
Post by Herbert Schulz
Post by Franck Pastor
Hello,
I'm facing a strange problem with PGF (a package for drawings, by
Till Tantau, that I am currently testing) and TeXShop. This
package needs and calls Gnuplot to plot functions. To do this,
you have to call pdflatex with the option "shell-escape". Here is
...
Howdy,
Is there a recent binary distribution of Gnuplot for Mac OS X?
Good Luck,
Herb Schulz
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
<><><><><><><><><><><><><><><><><><><><><>
LANL EES-6: MS D469
(505) 667-3420 (o)
(505) 665-3285 (fax)
Los Alamos National Laboratory
SM-30 Bikini Atoll Road
Los Alamos, NM 87545
<><><><><><><><><><><><><><><><><><><><><>
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Peter Lichtner
2006-01-15 18:32:09 UTC
Permalink
The problem may be that one needs to call gnuplotx rather than
gnuplot. In a gnuplot script using the fink installation:

#!/sw/bin/gnuplotx -persist

The gnuplot command /sw/bin/gnuplot is the shell script:

#!/bin/sh
export AQUATERM_PATH=/sw/Applications/AquaTerm.app
case ${DISPLAY-0} in
0) export GNUTERM=aqua ;;
esac
/sw/bin/gnuplotx "$@"

...Peter
Post by Franck Pastor
I agree, and that's what I did.
Franck
Post by Peter Lichtner
Best is to install gnuplot from fink.
...Peter
Post by Herbert Schulz
Post by Franck Pastor
Hello,
I'm facing a strange problem with PGF (a package for drawings,
by Till Tantau, that I am currently testing) and TeXShop. This
package needs and calls Gnuplot to plot functions. To do this,
you have to call pdflatex with the option "shell-escape". Here
...
Howdy,
Is there a recent binary distribution of Gnuplot for Mac OS X?
Good Luck,
Herb Schulz
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
<><><><><><><><><><><><><><><><><><><><><>
LANL EES-6: MS D469
(505) 667-3420 (o)
(505) 665-3285 (fax)
Los Alamos National Laboratory
SM-30 Bikini Atoll Road
Los Alamos, NM 87545
<><><><><><><><><><><><><><><><><><><><><>
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
<><><><><><><><><><><><><><><><><><><><><>
Peter C. Lichtner (***@lanl.gov)
LANL EES-6: MS D469
(505) 667-3420 (o)
(505) 665-3285 (fax)
Los Alamos National Laboratory
SM-30 Bikini Atoll Road
Los Alamos, NM 87545
<><><><><><><><><><><><><><><><><><><><><>



------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Bernhard Barkow
2006-01-15 17:59:01 UTC
Permalink
Hi,
Post by Herbert Schulz
Post by Franck Pastor
Hello,
I'm facing a strange problem with PGF (a package for drawings, by
Till Tantau, that I am currently testing) and TeXShop. This
package needs and calls Gnuplot to plot functions. To do this, you
have to call pdflatex with the option "shell-escape". Here is an
...
Howdy,
Is there a recent binary distribution of Gnuplot for Mac OS X?
if you don't use fink (or X11), there is a site with good
instructions at
http://www.lee-phillips.org/info/Macintosh/gnuplot.html ("Here it is").
As far as I remember, building it from sources was no problem at all
(maybe using some ./configure options). I've been using Gnuplot 4.0
with X11 as well as Aquaterm for quite some time now, works great.

Bernhard



____________________________________________________
_________________________________ Bernhard Barkow __
___________________ gpg key ID _ A89F09C45921020D __




------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Frank STENGEL
2006-01-15 18:44:20 UTC
Permalink
Post by Bernhard Barkow
Post by Herbert Schulz
Is there a recent binary distribution of Gnuplot for Mac OS X?
if you don't use fink (or X11), there is a site with good
instructions at
http://www.lee-phillips.org/info/Macintosh/gnuplot.html ("Here it is").
As far as I remember, building it from sources was no problem at
all (maybe using some ./configure options). I've been using Gnuplot
4.0 with X11 as well as Aquaterm for quite some time now, works great.
I just tried with this. It works straight out of the box. Frank
Pastor's example runs flawlessly... Maybe its fink?
--
Frank STENGEL (fstengel<at>mac.com)

------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Peter Lichtner
2006-01-15 19:09:31 UTC
Permalink
Yes it appears to be fink! I tried the version installed in /usr/
local/bin and that worked!
...Peter
Post by Frank STENGEL
Post by Bernhard Barkow
Post by Herbert Schulz
Is there a recent binary distribution of Gnuplot for Mac OS X?
if you don't use fink (or X11), there is a site with good
instructions at
http://www.lee-phillips.org/info/Macintosh/gnuplot.html ("Here it is").
As far as I remember, building it from sources was no problem at
all (maybe using some ./configure options). I've been using
Gnuplot 4.0 with X11 as well as Aquaterm for quite some time now,
works great.
I just tried with this. It works straight out of the box. Frank
Pastor's example runs flawlessly... Maybe its fink?
--
Frank STENGEL (fstengel<at>mac.com)
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
<><><><><><><><><><><><><><><><><><><><><>
Peter C. Lichtner (***@lanl.gov)
LANL EES-6: MS D469
(505) 667-3420 (o)
(505) 665-3285 (fax)
Los Alamos National Laboratory
SM-30 Bikini Atoll Road
Los Alamos, NM 87545
<><><><><><><><><><><><><><><><><><><><><>



------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Franck Pastor
2006-01-15 19:32:44 UTC
Permalink
Post by Frank STENGEL
Post by Bernhard Barkow
Post by Herbert Schulz
Is there a recent binary distribution of Gnuplot for Mac OS X?
if you don't use fink (or X11), there is a site with good
instructions at
http://www.lee-phillips.org/info/Macintosh/gnuplot.html ("Here it is").
As far as I remember, building it from sources was no problem at
all (maybe using some ./configure options). I've been using
Gnuplot 4.0 with X11 as well as Aquaterm for quite some time now,
works great.
I just tried with this. It works straight out of the box. Frank
Pastor's example runs flawlessly... Maybe its fink?
I suspect TeXShop is aware of the /usr/bin or /usr/local/bin
directories, but not of /sw/bin... If I use the following script
(named "pgfscript.engine" and placed in ~/Library/TeXShop/engines) to
run the LaTeX exemple that uses pgf, it works fine :

#!/bin/tcsh
set path= ($path /sw/bin)
pdflatex --shell-escape "$1"

In that case, is there any way to make TeXShop aware that gnuplot is
in /sw/bin, or have I to install the other implementation of Gnuplot ?------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Herbert Schulz
2006-01-15 19:44:57 UTC
Permalink
Post by Franck Pastor
I suspect TeXShop is aware of the /usr/bin or /usr/local/bin
directories, but not of /sw/bin... If I use the following script
(named "pgfscript.engine" and placed in ~/Library/TeXShop/engines)
#!/bin/tcsh
set path= ($path /sw/bin)
pdflatex --shell-escape "$1"
In that case, is there any way to make TeXShop aware that gnuplot
is in /sw/bin, or have I to install the other implementation of
Gnuplot ?
Howdy,

How about a symbolic link of /sw/bin (or the particular program that
is needed) placed in /usr/local/bin?

Good Luck,

Herb Schulz
(***@wideopenwest.com)


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Franck Pastor
2006-01-15 21:12:04 UTC
Permalink
Post by Herbert Schulz
Post by Franck Pastor
I suspect TeXShop is aware of the /usr/bin or /usr/local/bin
directories, but not of /sw/bin... If I use the following script
(named "pgfscript.engine" and placed in ~/Library/TeXShop/engines)
#!/bin/tcsh
set path= ($path /sw/bin)
pdflatex --shell-escape "$1"
In that case, is there any way to make TeXShop aware that gnuplot
is in /sw/bin, or have I to install the other implementation of
Gnuplot ?
Howdy,
How about a symbolic link of /sw/bin (or the particular program
that is needed) placed in /usr/local/bin?
Good Luck,
Herb Schulz
Thanks for the idea ! I'm a bit ashamed, I should have thought of it
myself ! It works now :-)------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Alain Matthes
2006-01-15 21:12:12 UTC
Permalink
Hello

I use Gnuplot version Fink with Texshop and with Textmate and i've no
problem with pgf for plotting.

I think it's a problem of path perhaps in etc/profile or
~/.bash_profile .
I don't know if the prefs of Texhsop can modify (mask) the paths.

Alain Matthes
Post by Herbert Schulz
Post by Franck Pastor
I suspect TeXShop is aware of the /usr/bin or /usr/local/bin
directories, but not of /sw/bin... If I use the following script
(named "pgfscript.engine" and placed in ~/Library/TeXShop/engines)
#!/bin/tcsh
set path= ($path /sw/bin)
pdflatex --shell-escape "$1"
In that case, is there any way to make TeXShop aware that gnuplot
is in /sw/bin, or have I to install the other implementation of
Gnuplot ?
Howdy,
How about a symbolic link of /sw/bin (or the particular program
that is needed) placed in /usr/local/bin?
Good Luck,
Herb Schulz
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Richard Koch
2006-01-15 21:33:43 UTC
Permalink
Folks,

TeXShop has a preference which points to the TeX binary
folder. The default is /usr/local/tetex/bin/powerpc-apple-darwin-
current.
Unfortunately, this preference cannot be a list of locations because
TeXShop concatenates it with the name of the binary to call
the binary. For example, to typeset with pdflatex, TeXShop
typically calls /usr/local/tetex/bin/powerpc-apple-darwin-current/
pdflatex.

One way to add other search locations to $PATH when calling a
TeX binary is to create a new "engine". The default XeLaTeX engine
is

-------------------
#!/bin/tcsh

set path= ($path /usr/local/teTeX/bin/powerpc-apple-darwin-current /
usr/local/bin)
xelatex "$1"
-------------------

so by modifying the path to include /sw/bin and changing xelatex to
pdflatex
you'd have a TeX which knows about /sw/bin.

Other solutions like symbolic links suggested in this thread also
work; I suppose
a new preference in TeXShop would be nice.

Dick
***@math.uoregon.edu



------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Franck Pastor
2006-01-15 22:12:44 UTC
Permalink
Post by Richard Koch
Folks,
TeXShop has a preference which points to the TeX binary
folder. The default is /usr/local/tetex/bin/powerpc-apple-darwin-
current.
Unfortunately, this preference cannot be a list of locations because
TeXShop concatenates it with the name of the binary to call
the binary. For example, to typeset with pdflatex, TeXShop
typically calls /usr/local/tetex/bin/powerpc-apple-darwin-current/
pdflatex.
One way to add other search locations to $PATH when calling a
TeX binary is to create a new "engine". The default XeLaTeX engine
is
-------------------
#!/bin/tcsh
set path= ($path /usr/local/teTeX/bin/powerpc-apple-darwin-current /
usr/local/bin)
xelatex "$1"
-------------------
so by modifying the path to include /sw/bin and changing xelatex to
pdflatex
you'd have a TeX which knows about /sw/bin.
Other solutions like symbolic links suggested in this thread also
work; I suppose
a new preference in TeXShop would be nice.
Dick
Thanks for those precisions !


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Franck Pastor
2006-01-15 22:07:06 UTC
Permalink
Post by Alain Matthes
Hello
I use Gnuplot version Fink with Texshop and with Textmate and i've
no problem with pgf for plotting.
I think it's a problem of path perhaps in etc/profile or
~/.bash_profile .
I don't know if the prefs of Texhsop can modify (mask) the paths.
Alain Matthes
Maybe you too have a symbolic link towards /sw/bin/gnuplot in /usr/
local/bin ?


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Alain Matthes
2006-01-15 22:31:45 UTC
Permalink
Post by Franck Pastor
Post by Alain Matthes
Hello
I use Gnuplot version Fink with Texshop and with Textmate and i've
no problem with pgf for plotting.
I think it's a problem of path perhaps in etc/profile or
~/.bash_profile .
I don't know if the prefs of Texhsop can modify (mask) the paths.
Alain Matthes
Maybe you too have a symbolic link towards /sw/bin/gnuplot in /usr/
local/bin ?
No, no symbolic link


This works for me :


moteur : pdflatex

in the prefs of Texshop
divers : distiller : Apple
moteur : path for the distiller /sw/bin

and it's fine

Alain Matthes


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Franck Pastor
2006-01-15 22:45:07 UTC
Permalink
Post by Alain Matthes
moteur : pdflatex
in the prefs of Texshop
divers : distiller : Apple
moteur : path for the distiller /sw/bin
OK, now I understand why it works with your installation and not
mine ;-) In "moteur", I have "/usr/local/bin", it is where
Ghostscript is installed in my computer. That explains why Gnuplot is
found in your installation without symbolic links or path
modification. So, you use Fink's Ghostscript ?


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Richard Koch
2006-01-16 05:38:05 UTC
Permalink
Folks,

I just updated TeXShop 2.08 on the web without changing the version
number.
ISO Latin 9 encoding now works, and the German
and Japanese localizations contain translations of new Menu items.

Dick

------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Bob Kerstetter
2006-01-16 18:57:36 UTC
Permalink
Post by Richard Koch
Folks,
I just updated TeXShop 2.08 on the web without changing the version
number.
ISO Latin 9 encoding now works, and the German
and Japanese localizations contain translations of new Menu items.
Dick
Hi Dick.

Thanks for all of your work and that of your team. The commercial
software developers could learn something about high quality,
"customer" service and good cheer by making you a case study.

Bob






------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Bastian Philipps
2006-01-16 19:19:17 UTC
Permalink
Post by Bob Kerstetter
Thanks for all of your work and that of your team. The commercial
software developers could learn something about high quality, "customer"
service and good cheer by making you a case study.
Bob
I can only second that.
Thanks for the fast and great work.

But it looks like that there is still a little glitch. When TeXShop
encountered the wrong encoding (for example configured to use latin9,
but opening utf-8), it always displayed an error message and reverted to
MacRoman. After some testing, it seems that the current version does
not do this anymore, it only displays the then faulty special characters.

Greetings
Bastian

BTW: Does anyone know a nice OS X Tool, which shows me the encoding a
file is using. Textwrangler does not display it and Smultron seems
unable to differenciate between latin9 or latin1

------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Bob Kerstetter
2006-01-16 20:11:31 UTC
Permalink
Post by Bastian Philipps
BTW: Does anyone know a nice OS X Tool, which shows me the encoding
a file is using. Textwrangler does not display it and Smultron
seems unable to differenciate between latin9 or latin1
Textwrangler does succeed at this now and then. However, a "Text
Files: Opening" option says, "If File's Encoding Can't be Guessed,
use: [Select an encoding option]. That sure seems to imply that TW
can divine the encoding sometimes but not all of the time.

Just a quick run around the Internet via google suggests the good
folks at BB may not be alone here. Lots of stuff says "detect
encoding where possible" or something similar. Is it really that
difficult?
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Peter Dyballa
2006-01-16 20:57:18 UTC
Permalink
Is it really that difficult?
Yes. It's close to impossible!

Remember that it can be UTF-8 and you're using less than 100
characters from the code range between 32 and 255 decimal: is it some
ISO-Latin, or UTF-8, or some DOS code page, or some Windows encoding,
or some local Thai, Cyrillic, Greek, Hebrew, Arabic encoding?
Bob Kerstetter
2006-01-17 00:39:53 UTC
Permalink
Post by Peter Dyballa
Is it really that difficult?
Yes. It's close to impossible!
Remember that it can be UTF-8 and you're using less than 100
characters from the code range between 32 and 255 decimal: is it
some ISO-Latin, or UTF-8, or some DOS code page, or some Windows
encoding, or some local Thai, Cyrillic, Greek, Hebrew, Arabic
encoding?
Peter Dyballa
2006-01-17 00:56:12 UTC
Permalink
Hum? So that's why we have to place the encoding at the top of web
page sources, so the browsers know what to do?
Yes. It makes thinks clear. Is the binary code A4 in hex
representation now meant to be presented as CURRENCY SIGN or CYRILLIC
CAPITAL LETTER UKRAINIAN IE or EURO SIGN or LATIN CAPITAL LETTER C
WITH DOT ABOVE or LATIN CAPITAL LETTER I WITH MACRON or THAI
CHARACTER KHO KHWAI? (And I did not look into MS or IBM DOS or winDOS
or NeXT or HP-Roman or Mac-Roman or ...)
Also, sometime during the last week or so, someone on this list
wrote then utf8 and utf-8 are different encodings. Is that correct
or did I, hopefully, misread that?
No, only in TeX, and there it comes from the names of different STY
files. For TeX too UTF-8 is UTF-8. Both STY files handle some things
differently, so some way was needed to choose between them ...

--
Greetings

Pete

UNIX is user friendly, it's just picky about who its friends are.


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/

Stefan Walsen
2006-01-16 20:27:19 UTC
Permalink
Hi,
Post by Bastian Philipps
BTW: Does anyone know a nice OS X Tool, which shows me the encoding
a file is using. Textwrangler does not display it and Smultron
seems unable to differenciate between latin9 or latin1
You might want to try

http://www.nebulous.org/handy/text_recoder.html

With Text Recoder, you can browse through different encodings for a
file and see which one comes out correctly, then save the file in an
encoding of your choice.

I already mentioned this app in May 2005, and now I know that it
works on Tiger, too. :)
BTW: it's freeware.

Stefan
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Peter Dyballa
2006-01-16 21:06:17 UTC
Permalink
Post by Stefan Walsen
You might want to try
http://www.nebulous.org/handy/text_recoder.html
It might be easier to use a practice as with GNU Emacs: among the few
first lines add a comment like:

;;; -*- mode: Text; coding: thai-tis620; -*-

or

%% -*- mode: LaTeX; coding: iso-8859-15; -*-

And this is already realised in two ways! First you can use TeXShop
specials à la '%!TEX encoding = <some value>' (or '%&encoding= ' in
earlier versions), and second there is '\usepackage[latin9]
{inputenc}' -- what is there needed more? (A parser to look for
inputenc lines too if there is no TS special.)

--
Mit friedvollen Grüßen

Pete

Either this man is dead or my watch has stopped. - Groucho Marx


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Stefan Walsen
2006-01-16 21:40:55 UTC
Permalink
Post by Peter Dyballa
It might be easier to use a practice as with GNU Emacs: among the
;;; -*- mode: Text; coding: thai-tis620; -*-
or
%% -*- mode: LaTeX; coding: iso-8859-15; -*-
And this is already realised in two ways! First you can use TeXShop
specials à la '%!TEX encoding = <some value>' (or '%&encoding= ' in
earlier versions), and second there is '\usepackage[latin9]
{inputenc}' -- what is there needed more? (A parser to look for
inputenc lines too if there is no TS special.)
well, this neither tells you which encoding some file you got as an
email-attachment is in, nor does it change that file to the encoding
you want it to have.


Stefan------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Peter Dyballa
2006-01-16 20:51:58 UTC
Permalink
Post by Bastian Philipps
BTW: Does anyone know a nice OS X Tool, which shows me the encoding
a file is using. Textwrangler does not display it and Smultron
seems unable to differenciate between latin9 or latin1
There is none -- except:

create two files in each of these two encodings and add as comment
lines these two lines:

¤ = 244 = 164 = A4 = U+00A4 = C2 A4 : CURRENCY SIGN => ISO Latin-1
€ = 244 = 164 = A4 = U+20AC = E2 82 AC : EURO SIGN => ISO Latin-9

Since the first four columns contain exactly the same codes, you can
judge upon seeing € or ¤ which encoding you're currently in ...

--
Mit friedvollen Grüßen

Pete

"A designer knows he has arrived at perfection not when there is no
longer anything to add, but when there is no longer anything to
take away."
- Antoine de Saint-Exupéry


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Bruno Voisin
2006-01-15 20:46:04 UTC
Permalink
Post by Franck Pastor
I suspect TeXShop is aware of the /usr/bin or /usr/local/bin
directories, but not of /sw/bin...
Remember what Gerben said on the ~/.MacOSX/environment.plist problem
(see below). This tells us that TeXShop is indeed aware of /usr/local/
bin and /usr/local/teTeX/bin/powerpc-apple-darwin-current, but of
these only. They are set in the Engine tab of its Prefs; I don't know
whether it's possible to specify a "multiple" path, such as "/usr/
local/bin;/sw/bin" (I've no idea of the correct syntax).

Bruno Voisin
Post by Franck Pastor
De : Gerben Wierda
Date : 31 mai 2005 23:55:20 HAEC
À : TeX on Mac OS X Mailing List
Objet : Rép : [OS X TeX] epstopdf can't find Ghostscript
Répondre à : TeX on Mac OS X Mailing List
[...]
The correct way is to have the GUI *application* (and not a
global setting for all GUI applications) set the right PATH
before executing commands.
You mean that at login-time the correct values for PATH or path
should be set? And this should work because any process created by
a GUI app should have then too the right settings?
No, what I mean is that if a GUI app requires non-default setting
for its working (and that generally means running subprocesses) it
should keep its own PATH setting. TeXShop does this in its
Preferences (in the Engine tab).
The Apple Frameworks for running subprocesses have the possibility
to pass environment variables to that subprocess. Hence, TeXShop
passes an updated environment to the subprocess including a PATH
containing and /usr/local/bin and /usr/local/teTeX/bin/powerpc-
apple-darwin-current (or whatever you set in preferences)
------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Franck Pastor
2006-01-15 21:16:55 UTC
Permalink
Post by Bruno Voisin
Post by Franck Pastor
I suspect TeXShop is aware of the /usr/bin or /usr/local/bin
directories, but not of /sw/bin...
Remember what Gerben said on the ~/.MacOSX/environment.plist
problem (see below). This tells us that TeXShop is indeed aware of /
usr/local/bin and /usr/local/teTeX/bin/powerpc-apple-darwin-
current, but of these only. They are set in the Engine tab of its
Prefs; I don't know whether it's possible to specify a "multiple"
path, such as "/usr/local/bin;/sw/bin" (I've no idea of the correct
syntax).
Bruno Voisin
I have just created a symbolic link to /sw/bin/gnuplot in /usr/local/
bin (from a idea of Herbert Schulz), and there is no problem anymore.
Before, I had the same idea as you and tried to put

usr/local/teTeX/bin/powerpc-apple-darwin-current:/sw/bin

in the preferences of TeXShop, with no results. But it doesn't matter
very much now.

Thanks again,

Franck Pastor------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
& FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
Loading...