diff options
| author | Andrea Bastoni <bastoni@sprg.uniroma2.it> | 2010-04-09 00:01:41 -0400 |
|---|---|---|
| committer | Andrea Bastoni <bastoni@sprg.uniroma2.it> | 2010-04-09 00:01:41 -0400 |
| commit | 36b6614fa9ea3c2656aedb385c5c4154917aa618 (patch) | |
| tree | 570bbea7e4ab1dcaf951857d41631e7ec301b195 | |
| parent | fa1fb842fe42e07508cc8f6cf371aeb468b077a3 (diff) | |
Add support for postscript terminal (debian doesn't have pdf :( )
| -rwxr-xr-x | gnuplot.py | 6 |
1 files changed, 5 insertions, 1 deletions
| @@ -3,7 +3,7 @@ import defapp | |||
| 3 | from subprocess import Popen, PIPE | 3 | from subprocess import Popen, PIPE |
| 4 | from optparse import make_option as o | 4 | from optparse import make_option as o |
| 5 | 5 | ||
| 6 | FORMATS = ['png', 'eps', 'pdf', 'show'] | 6 | FORMATS = ['png', 'eps', 'pdf', 'show', 'ps'] |
| 7 | STYLES = ['points', 'lines', 'linespoints'] | 7 | STYLES = ['points', 'lines', 'linespoints'] |
| 8 | 8 | ||
| 9 | class CommandBuffer(object): | 9 | class CommandBuffer(object): |
| @@ -32,6 +32,10 @@ def gnuplot_cmd(graphs, title=None, ylabel=None, xlabel=None, | |||
| 32 | terminal = 'postscript eps' | 32 | terminal = 'postscript eps' |
| 33 | if term_opts is None: | 33 | if term_opts is None: |
| 34 | term_opts = 'color blacktext solid linewidth 1.0' | 34 | term_opts = 'color blacktext solid linewidth 1.0' |
| 35 | elif format == 'ps': | ||
| 36 | terminal = 'postscript' | ||
| 37 | if term_opts is None: | ||
| 38 | term_opts = 'color enhanced' | ||
| 35 | elif format == 'pdf': | 39 | elif format == 'pdf': |
| 36 | terminal = 'pdf' | 40 | terminal = 'pdf' |
| 37 | if term_opts is None: | 41 | if term_opts is None: |
