[metapost] problem with drawoptions and fake Euro symbol

Mojca Miklavec mojca.miklavec.lists at gmail.com
Thu Nov 15 03:13:43 CET 2007

On 11/14/07, Stephan Hennig wrote:

> There are several items in gnuplot I would like to see changed:
> * boxes aren't closed strokes,
> * a hook to provide a user-defined LaTeX preamble or MetaPost code
>   is missing,
> * the font issue discussed here.

Hello both,

I have written a ConTeXt terminal for Gnuplot one or two years ago,
based on metapost (at least I started by cloning portions of code from
the metapost terminal and kept improving it gradually). Actually, the
terminal returns pure metapost code, ConTeXt is there only to surround
the code with a proper header and to take care of typesetting labels.
(Well, one can plot graphs on the fly in the middle of the ConTeXt
document as well, but that's something else.) With this one:

* boxes are closed

* it doesn't work with LaTeX, but you can provide any CouTeXt code you
wish (and generally they're not so much different), for example, it's
no problem to say
    set term context standalone header '\font\a="Zapfino"\a'
and process the resulting document with XeTeX. (Not that the font
would be of any use in that graph, but just as proof of concept :)

Also, you can easily say
    set xlabel 'any \bf bold \color[red]{red unicod€} text'
and it works without any problems (with all other encodings as well).

* I didn't try your code, but in general what works in other (ConTeXt)
documents should work with gnuplot terminal as well (after lengthy
debugging sessions with really extensive Hans's and Taco's support -
even makempx has been rewritten to ruby at that time :).

> Could you please point me to some place where gnupot and mp terminal
> related stuff is best discussed?

There is a gnuplot mailing list, but just to warn you: people there
have some knowledge about TeX and some about metapost, but there might
be no real TeX/metapost expert. And even if you write a working patch,
it might take *a lot* of time before some developer is willing to test
the patch, and it might take more energy to make your patch into the
core that the energy you needed to write it.

I have asked several times to include the terminal into CVS, but it
hasn't happened yet. Well, I guess that I should insist more, but ...
They replied me several times that they're not willing to invest time
into installing some recent TeX distribution (TeX Live 2007 wasn't
available yet when I first asked them, but even after it came out the
reply was more or less the same.) I admit that it's also my fault
since I should keep asking them (or at least write some decent
documentation about it), but nevertheless ...

I was thinking about backporting some of the functionality from
ConTeXt terminal to MetaPost again (to apply my imporvements) or even
to modify the ConTeXt terminal in such a way that it would output some
(slightly more advanced) pure metapost code, but I don't have much
motivation if not even the basic version can make it into CVS. (Now
I'm kept busy enough drawing dozens of graphs with it each week, so I
will be at least able to say that I made a good use of it, even if it
never makes into the official binary.)

Some examples (taken from gnuplot demos) can be found here:

There are some basic things written on
but I can answer any more specific questions.

Another example: Peter Hedwig has written a lua-based TikZ LaTeX
(should really be adapted for ConTeXt and plain TeX) terminal for
gnuplot, which is really useful and I guess that quite some people use
it, but I doubt that anyone on the gnuplot developers' mailing list is
even aware of that. And certainly nobody is talking about including it
into the official distribution, which is really a pitty, esp. because
the "latex" terminal is useless, and there is no single other terminal
for pdfTeX available in the official gnuplot version at the moment.


There are apparently some PostScript geeks among gnuplot developers
:), so they have made a really nice epslatex terminal, but that's only
for LaTeX and only for dvips.

> Even though, what you wrote sounds not so enthusiastic.

It depends. There are some developers (Timothée Lecomte, in
particular) who are really enthusiastic and willing to implement and
test many new ideas to improve gnuplot. But one needs a proper
approach when talking to them.


More information about the metapost mailing list