Difference between revisions of "Gnuplot Development"

From Wiki
Jump to navigation Jump to search
m (→‎High priority: a few issues resolved)
(just a few internal notes (the page should disappear as soon as possible ;))
Line 1: Line 1:
Different remarks about gnuplot development
+
== Known bugs ==
 
 
Hans's note:
 
 
 
Once we have lua in place it should not be that difficult to make a mechanism that works as follows:
 
* context calls gnuplot and opens a socket
 
* and starts waiting for gp to finish
 
* when gnuplot needs dimensions it talks back via the socket
 
* tex executes the command send by the socket
 
* etc
 
it needs some thinking but i think that it is possible
 
 
 
== What has to be fixed in m-gnuplot.tex ==
 
  
* Is it possible to get rid of "^M" at the end of lines
+
* mathematics
* Add
 
 
<texcode>
 
<texcode>
\defineGNUPLOThandle{eps}{postscript eps color}{eps}{texmfstart newpstopdf \GNUPLOTfile.eps}{\GNUPLOTfile.pdf}
+
\startGNUPLOTscript{exp}
 +
plot [0:3] 2/sqrt(pi)*exp(-x**2) t '$\frac{2}{\sqrt{\pi}}e^{-x^2}$'
 +
\stopGNUPLOTscript
 
</texcode>
 
</texcode>
* [Urgently] remove <code>start</code> from
+
* comments
 
<texcode>
 
<texcode>
{\executesystemcommand{start /MIN pgnuplot \GNUPLOTfile.gpd}}
+
\startGNUPLOTscript{sin}
 +
# this comment should be ignored
 +
plot sin(x)
 +
\stopGNUPLOTscript
 
</texcode>
 
</texcode>
:No need for /MIN and possibly use gnuplot instead of pgnuplot
+
* doesn't work with XeTeX yet
* perhaps some <code>--iftouched</code> switches
+
* Rotated PostScript images
 +
-dAutoRotatePages=/PageByPage
 +
 
 +
== TODO: ==
 +
 
 +
=== ConTeXt + terminal ===
 +
 
 +
* contour plot, <code>set style fill pattern</code>
 +
* images
 +
* handling fonts / set label "font"
 +
* colour palettes
 +
* smooth shading
 +
 
 +
=== Efficiency ===
 +
 
 +
* optimize the number of gnuplot runs (if possible, gnuplot should be run only once)
 +
* optimize the number of times for loading/converting an already used graphic
 +
 
 +
=== Gnuplot core ===
 +
 
 +
* CLIP lines & points
 +
* MITTERED/BUTT
 +
* encoding: bigger list, it's not updated in help (encoding), add utf-8
 +
* pm3d - smooth shading
 +
 
 +
=== Obscure ideas ===
 +
* <code>set decimalsign ','</code> based on language setting or locales
  
 
== What has to be added to m-gnuplot.tex to support ConTeXt terminal ==
 
== What has to be added to m-gnuplot.tex to support ConTeXt terminal ==
Line 48: Line 66:
 
=== Legend ===
 
=== Legend ===
 
* [HTH] = Need Hans's or Taco's Help
 
* [HTH] = Need Hans's or Taco's Help
 +
 +
Different remarks about gnuplot development
 +
 +
== Notes ==
 +
 +
=== Hans's note ===
 +
 +
Once we have lua in place it should not be that difficult to make a mechanism that works as follows:
 +
* context calls gnuplot and opens a socket
 +
* and starts waiting for gp to finish
 +
* when gnuplot needs dimensions it talks back via the socket
 +
* tex executes the command send by the socket
 +
* etc
 +
it needs some thinking but i think that it is possible
 +
 +
=== closed curves in parametric plots ===
 +
* it's probably not seen that easy, but if you want a circle with --cycle, set trange [0:2*pi]

Revision as of 02:06, 25 August 2006

Known bugs

  • mathematics
\startGNUPLOTscript{exp}
plot [0:3] 2/sqrt(pi)*exp(-x**2) t '$\frac{2}{\sqrt{\pi}}e^{-x^2}$'
\stopGNUPLOTscript
  • comments
\startGNUPLOTscript{sin}
# this comment should be ignored
plot sin(x)
\stopGNUPLOTscript
  • doesn't work with XeTeX yet
  • Rotated PostScript images
-dAutoRotatePages=/PageByPage

TODO:

ConTeXt + terminal

  • contour plot, set style fill pattern
  • images
  • handling fonts / set label "font"
  • colour palettes
  • smooth shading

Efficiency

  • optimize the number of gnuplot runs (if possible, gnuplot should be run only once)
  • optimize the number of times for loading/converting an already used graphic

Gnuplot core

  • CLIP lines & points
  • MITTERED/BUTT
  • encoding: bigger list, it's not updated in help (encoding), add utf-8
  • pm3d - smooth shading

Obscure ideas

  • set decimalsign ',' based on language setting or locales

What has to be added to m-gnuplot.tex to support ConTeXt terminal

What has to be added to context.trm

High priority

  • fix the syntax for
set terminal context
  • write documentation
  • [HTH] add \switchtobodyfont[whateverisprovided]\strut to evert \sometxt: try using (implementing first) \GPtext instead of \sometxt

Middle priority

  • support different font sizes
  • check if everything is documented well enough in help

Low priority

  • implement with_image: once it's clear how to do it
  • study the code for palettes, implement them and document them
  • (need some interference with the core code) improve the code for
draw_color_smooth_box(MODE_SPLOT) in graph3d.c -> color.c

Legend

  • [HTH] = Need Hans's or Taco's Help

Different remarks about gnuplot development

Notes

Hans's note

Once we have lua in place it should not be that difficult to make a mechanism that works as follows:

  • context calls gnuplot and opens a socket
  • and starts waiting for gp to finish
  • when gnuplot needs dimensions it talks back via the socket
  • tex executes the command send by the socket
  • etc

it needs some thinking but i think that it is possible

closed curves in parametric plots

  • it's probably not seen that easy, but if you want a circle with --cycle, set trange [0:2*pi]