home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 22 gnu / 22-gnu.zip / gnuplapi.zip / gnuplot-api-os2 / examples / GnuplotAPI.INF (.txt) < prev    next >
Encoding:
OS/2 Help File  |  2001-03-07  |  104.0 KB  |  2,952 lines

  1.  
  2. ΓòÉΓòÉΓòÉ 1. About ΓòÉΓòÉΓòÉ
  3.  
  4. Generated on Wed Mar  7 02:41:15 2001, by Perl version 5.00553, pod2ipf version 
  5. 1.16 with arguments "--head-off=1" "--title" "Gnuplot low-level plotting API" 
  6. "--by-files" "Gnuplot.pm" "GnuplotTerminals.pod" in directory 
  7. I:/get/gnuplot-api-os2/examples. 
  8.  
  9.  
  10. ΓòÉΓòÉΓòÉ 2. Gnuplot - lowlevel graphics using gnuplot drawing routines. ΓòÉΓòÉΓòÉ
  11.  
  12. Gnuplot - lowlevel graphics using gnuplot drawing routines. 
  13.  
  14.      NAME 
  15.      SYNOPSIS 
  16.      EXPORTS 
  17.         -  Exportable and export tags: 
  18.      DESCRIPTION 
  19.      gnuplot term/README 
  20.      Using Term::Gnuplot from C libraries 
  21.         -  Runtime link with gnuplot DLL 
  22.         -  Runtime link of a Perl module with Term::Gnuplot 
  23.         -  Using different Plotting libraries 
  24.      Examples 
  25.         -  High-level plotting 
  26.         -  Multifile plotting 
  27.      BUGS and LIMITATIONS 
  28.      SEE ALSO 
  29.  
  30.  
  31. ΓòÉΓòÉΓòÉ 2.1. NAME ΓòÉΓòÉΓòÉ
  32.  
  33. Term::Gnuplot - lowlevel graphics using gnuplot drawing routines.  Go Up 
  34.  
  35.  
  36. ΓòÉΓòÉΓòÉ 2.2. SYNOPSIS ΓòÉΓòÉΓòÉ
  37.  
  38.   use Term::Gnuplot ':ALL';
  39.   list_terms();
  40.   change_term('dumb') or die "Cannot set terminal.\n";
  41.   term_init();                          # init()
  42.   term_start_plot();                    # graphics();
  43.   $xmax = scaled_xmax();
  44.   $ymax = scaled_ymax();
  45.   linetype(-2);
  46.   move(0,0);
  47.   vector($xmax-1,0);
  48.   vector($xmax-1,$ymax-1);
  49.   vector(0,$ymax-1);
  50.   vector(0,0);
  51.   justify_text(LEFT);
  52.   put_text(h_char()*5, $ymax - v_char()*3,"Terminal Test, Perl");
  53.   $x = $xmax/4;
  54.   $y = $ymax/4;
  55.   $xl = h_tic()*5;
  56.   $yl = v_tic()*5;
  57.   linetype(2);
  58.   arrow($x,$y,$x+$xl,$y,1);
  59.   arrow($x,$y,$x+$xl/2,$y+$yl,1);
  60.   arrow($x,$y,$x,$y+$yl,1);
  61.   arrow($x,$y,$x-$xl/2,$y+$yl,0);
  62.   arrow($x,$y,$x-$xl,$y,1);
  63.   arrow($x,$y,$x-$xl,$y-$yl,1);
  64.   arrow($x,$y,$x,$y-$yl,1);
  65.   arrow($x,$y,$x+$xl,$y-$yl,1);
  66.   term_end_plot();                      # text();
  67.   Term::Gnuplot::reset();
  68.  Go Up 
  69.  
  70.  
  71. ΓòÉΓòÉΓòÉ 2.3. EXPORTS ΓòÉΓòÉΓòÉ
  72.  
  73. None by default.  Go Up 
  74.  
  75.  
  76. ΓòÉΓòÉΓòÉ 2.3.1. Exportable and export tags: ΓòÉΓòÉΓòÉ
  77.  
  78.  :SETUP 
  79.  
  80.                   change_term test_term init_terminal list_terms  plot_outfile_set
  81.                   term_init term_start_plot term_end_plot
  82.                   term_start_multiplot term_end_multiplot plotsizes_scale
  83.                   setcanvas
  84.  
  85.  :JUSTIFY 
  86.  
  87.                   LEFT CENTRE RIGHT
  88.  
  89.  :FIELDS 
  90.  
  91.                   name description xmax ymax v_char h_char v_tic h_tic
  92.                   scaled_xmax scaled_ymax
  93.  
  94.  :METHODS 
  95.  
  96.                   init scale graphics linetype move vector point text_angle
  97.                   justify_text put_text arrow text
  98.  
  99.  %description Hash of name => description pairs.  In particular, keys 
  100.         %description contains names of supported terminals.
  101.  
  102.  :ALL   All of the above. 
  103.   Go Up 
  104.  
  105.  
  106. ΓòÉΓòÉΓòÉ 2.4. DESCRIPTION ΓòÉΓòÉΓòÉ
  107.  
  108. Below I include the contents of the file term/README from gnuplot distribution 
  109. (see gnuplot term/README). It explains the meaning of the methods of SYNOPSIS.
  110.  
  111.  All methods are supported under Perl, the options method is available as 
  112. set_options(). The discription below includes underscores, that are deleted in 
  113. the perl interface.
  114.  
  115.  The functions which are not included in the description below: 
  116.  
  117.  change_term($newname) 
  118.  
  119.  test_term() 
  120.  
  121.  init_terminal() self-explanatory. 
  122.  
  123.  list_terms() Print names/descriptions of supported terminals.
  124.  
  125.  plot_outfile_set($filename) set the output file.  This should be done before 
  126.         setting the terminal type.
  127.  
  128.  plotsizes_scale($xfactor, $yfactor) set the size of the output device (such as 
  129.         a graphic file) in fractions of the default size. Some output drivers 
  130.         may ignore this request.  The request is active until the next request.
  131.  
  132.          Does not change sizes reported by xmax() and ymax()!  After such a 
  133.         call one should use the following calls:
  134.  
  135.  scaled_xmax(), scaled_ymax() Report xmax() and ymax() corrected by the scaling 
  136.         factors given to plotsizes_scale().
  137.  
  138.  term_init(), term_start_plot(), term_end_plot() higher-level functions 
  139.         variants of init(), graphics(), text().  Should be prefered over 
  140.         init(), graphics(), text() if the output file is changed, since they 
  141.         take into account resetting of output file mode (if needed).
  142.  
  143.  term_start_multiplot(), term_end_multiplot() Interfaces to C functions with 
  144.         the same names.  How to use them outside of gnuplot proper is not clear.
  145.  
  146.  _term_descrs() Returns hash of names/descriptions of supported terminals 
  147.         (available as %Term::Gnuplot::description too).
  148.  
  149.  setcanvas($ptk_canvas) Sets the Tk widget for direct-draw operations (may be 
  150.         used with terminal 'tkcanvas' with the option 'tkperl_canvas'). 
  151.  
  152.  NOTE. Some terminals require calling set_options() before init()!  Go Up 
  153.  
  154.  
  155. ΓòÉΓòÉΓòÉ 2.5. gnuplot term/README ΓòÉΓòÉΓòÉ
  156.  
  157. DOCUMENTATION FOR GNUPLOT TERMINAL DRIVER WRITERS 
  158.  
  159.  By Russell Lang 1/90
  160.  
  161.  Updated for new file layout by drd 4/95
  162.  
  163.  Paragraphs about inclusion of TERM_HELP added by rcc 1/96
  164.  
  165.  No change to the interface between gnuplot and the terminal drivers, but we 
  166. would like to make the terminal drivers standalone 
  167.  
  168. 1) in order move the support for the terminal drivers outside of the
  169.    support for the main program, thereby encouraging a library of
  170.    contributed drivers
  171. 2) To make it easy for users to add contributed drivers, by adding
  172.    a single #include line to term.h
  173. 3) To allow individual compilation on DOS, to save the overlay
  174.    manager from having to load _all_ drivers together.
  175.  
  176. CORRECTION - scale() interface is no longer supported, since it is incompatible 
  177. with multiplot.
  178.  
  179.  Whole of terminal driver should be contained in one <driver>.trm file, with a 
  180. fairly strict layout as detailed below - this allows the gnuplot maintainers to 
  181. change the way the terminal drivers are compiled without having to change the 
  182. drivers themselves.
  183.  
  184.  term.h, and therefore each file.trm file, may be loaded more than once, with 
  185. different sections selected by macros.
  186.  
  187.  Each driver provides all the functions it needs, and a table of function 
  188. pointers and other data to interface to gnuplot. The table entry is currently 
  189. defined as follows in plot.h: 
  190.  
  191.   struct TERMENTRY {
  192.  
  193.   /* required entries */
  194.  
  195.         char *name;
  196.         char *description;
  197.         unsigned int xmax,ymax,v_char,h_char,v_tic,h_tic;
  198.  
  199.         void (*options) __PROTO((void));
  200.         void (*init) __PROTO((void));
  201.         void (*reset) __PROTO((void));
  202.         void (*text) __PROTO((void));
  203.         int (*scale) __PROTO((double, double));
  204.         void (*graphics) __PROTO((void));
  205.         void (*move) __PROTO((unsigned int, unsigned int));
  206.         void (*vector) __PROTO((unsigned int, unsigned int));
  207.         void (*linetype) __PROTO((int));
  208.         void (*put_text) __PROTO((unsigned int, unsigned int,char*));
  209.  
  210.   /* optional entries */
  211.  
  212.         int (*text_angle) __PROTO((int));
  213.         int (*justify_text) __PROTO((enum JUSTIFY));
  214.         void (*point) __PROTO((unsigned int, unsigned int,int));
  215.         void (*arrow) __PROTO((unsigned int, unsigned int, unsigned int,
  216.                            unsigned int, int));
  217.    int (*set_font) __PROTO((char *font));  /* "font,size" */
  218.         void (*set_pointsize) __PROTO((double size)); /* notification of set pointsize */
  219.         int flags; /* various flags */
  220.    void (*suspend) __PROTO((void)); /* after one plot of multiplot */
  221.    void (*resume) __PROTO((void));  /* before subsequent plot of multiplot */
  222.    void (*boxfill) __PROTO((int style, unsigned int x1, unsigned int y1, unsigned int width, unsigned int height)); /* clear part of multiplot */
  223.    void (*linewidth) __PROTO((double linewidth));
  224.    void (*pointsize) __PROTO((double pointsize));
  225.   };
  226.  
  227. One consequence of (1) is that we would like drivers to be backwards compatible 
  228. - drivers in the correct form below should work in future versions of gnuplot 
  229. without change. C compilers guarantee to fill unitialised members of a 
  230. structure to zero, so gnuplot can detect old drivers, in which fields have not 
  231. been initalised, and can point new interface entry pointers to dummy functions.
  232.  
  233.  We can add fields to the terminal structure, but only at the end of the list. 
  234. If you design a terminal that cant work without a new interface being defined, 
  235. and consequent changes to the main gnuplot source, please contact 
  236. bug-gnuplot@dartmouth.edu simply to ensure that you have the most up to date 
  237. defn of the terminal structure. Also, please ensure that the 'set term' command 
  238. checks for 0 values in added fields when an old driver is selected, and a 
  239. pointer to a suitable 'cant do' function is provided. It is therefore not 
  240. required (and in fact not possible) to add padding fields to the end of all drivers.
  241.  
  242.  Similarly, if you add an optional field to an old driver, take care to ensure 
  243. that all intervening fields are padded with zeros.
  244.  
  245.  Some of the above fields are required - this should not be a problem, since 
  246. they were all required in earlier releases of gnuplot. The later fields are 
  247. interfaces to capabilities that not all devices can do, or for which the 
  248. generic routines provided should be adequate. There are several null ('cant 
  249. do') functions provided by term.c which a driver can reference in the table. 
  250. Similarly, for bitmap devices, there are generic routines for lines and text 
  251. provided by bitmap.c
  252.  
  253.  Here's a brief description of each variable:
  254.  
  255.  The char *name is a pointer to a string containing the name of the terminal. 
  256. This name is used by the 'set terminal' and 'show terminal' commands. The name 
  257. must be unique and must not be confused with an abbreviation of another name. 
  258. For example if the name "postscript" exists, it is not possible to have another 
  259. name "postscript2". Keep the name under 15 characters.
  260.  
  261.  The char *description is a pointer to a string containing a description of the 
  262. terminal, which is displayed in response to the 'set terminal' command. Keep 
  263. the description under 60 characters.
  264.  
  265.  xmax is the maximum number of points in the x direction. The range of points 
  266. used by gnuplot is 0 to xmax-1.
  267.  
  268.  ymax is the maximum number of points in the y direction. The range of points 
  269. used by gnuplot is 0 to ymax-1.
  270.  
  271.  v_char is the height of characters, in the same units as xmax and ymax. The 
  272. border for labelling at the top and bottom of the plot is calculated using 
  273. v_char. v_char is used as the vertical line spacing for characters.
  274.  
  275.  h_char is the width of characters, in the same units as xmax and ymax. The 
  276. border for labelling at the left and right of the plot is calculated using 
  277. h_char, for example. If the _justify_text function returns FALSE, h_char is 
  278. used to justify text right or centre.  If characters are not fixed width, then 
  279. the _justify_text function must correctly justify the text.
  280.  
  281.  v_tic is the vertical size of tics along the x axis, in the same units as ymax.
  282.  
  283.  h_tic is the horizontal size of tics along the y axis, in the same units as xmax.
  284.  
  285.  v_tic and h_tic should give tics of the same physical size on the output. The 
  286. ratio of these two quantities is used by gnuplot to set the aspect ratio to 1 
  287. so that circles appear circular when 'set size square' is active.
  288.  
  289.  All the above values need not be static - values can be substituted into the 
  290. table during terminal initialisation, based on options for example.
  291.  
  292.  Here's a brief description of what each term.c function does:
  293.  
  294.  _options()  Called when terminal type is selected. This procedure should parse 
  295. options on the command line.  A list of the currently selected options should 
  296. be stored in term_options[] in a form suitable for use with the set term 
  297. command.  term_options[] is used by the save command.  Use options_null() if no 
  298. options are available. 
  299.  
  300.  _init()  Called once, when the device is first selected.  This procedure 
  301. should set up things that only need to be set once, like handshaking and 
  302. character sets etc... There is a global variable 'pointsize' which you might 
  303. want to use here. If set pointsize is issued after init has been called, the 
  304. set_pointsize() function is called.
  305.  
  306.  _reset()  Called when gnuplot is exited, the output device changed or the 
  307. terminal type changed.  This procedure should reset the device, possibly 
  308. flushing a buffer somewhere or generating a form feed.
  309.  
  310.  _scale(xs,ys) Called just before _graphics(). This takes the x and y scaling 
  311. factors as information. If the terminal would like to do its own scaling, it 
  312. returns TRUE. Otherwise, it can ignore the information and return FALSE: 
  313. do_plot will do the scaling for you. null_scale is provided to do just this, so 
  314. most drivers can ignore this function entirely. The Latex driver is currently 
  315. the only one providing its own scaling. PLEASE DO NOT USE THIS INTERFACE - IT 
  316. IS NOT COMPATIBLE WITH MULTIPLOT.
  317.  
  318.  _graphics()  Called just before a plot is going to be displayed.  This 
  319. procedure should set the device into graphics mode.  Devices which can't be 
  320. used as terminals (like plotters) will probably be in graphics mode always and 
  321. therefore won't need this.
  322.  
  323.  _text()  Called immediately after a plot is displayed.  This procedure should 
  324. set the device back into text mode if it is also a terminal, so that commands 
  325. can be seen as they're typed.  Again, this will probably do nothing if the 
  326. device can't be used as a terminal. This call can be used to trigger conversion 
  327. and output for bitmap devices.
  328.  
  329.  _move(x,y)  Called at the start of a line.  The cursor should move to the 
  330. (x,y) position without drawing.
  331.  
  332.  _vector(x,y)  Called when a line is to be drawn.  This should display a line 
  333. from the last (x,y) position given by _move() or _vector() to this new (x,y) position.
  334.  
  335.  _linetype(lt)  Called to set the line type before text is displayed or line(s) 
  336. plotted.  This procedure should select a pen color or line style if the device 
  337. has these capabilities. lt is an integer from -2 to 0 or greater. An lt of -2 
  338. is used for the border of the plot. An lt of -1 is used for the X and Y axes. 
  339. lt 0 and upwards are used for plots 0 and upwards. If _linetype() is called 
  340. with lt greater than the available line types, it should map it to one of the 
  341. available line types. Most drivers provide 9 different linetypes (lt is 0 to 8).
  342.  
  343.  _put_text(x,y,str)  Called to display text at the (x,y) position, while in 
  344. graphics mode.  The text should be vertically (with respect to the text) 
  345. justified about (x,y).  The text is rotated according to _text_angle and then 
  346. horizontally (with respect to the text) justified according to _justify_text.
  347.  
  348.  The following are optional 
  349.  
  350.  _text_angle(ang)  Called to rotate the text angle when placing the y label. If 
  351. ang = 0 then text is horizontal.  If ang = 1 then text is vertically upwards. 
  352. Returns TRUE if text can be rotated, FALSE otherwise. [But you must return TRUE 
  353. if called with ang=0]
  354.  
  355.  _justify_text(mode)  Called to justify text left, right or centre. If mode = 
  356. LEFT then text placed by _put_text is flushed left against (x,y). If mode = 
  357. CENTRE then centre of text is at (x,y). If mode = RIGHT then text is placed 
  358. flushed right against (x,y). Returns TRUE if text can be justified Returns 
  359. FALSE otherwise and then _put_text assumes text is flushed left; justification 
  360. of text is then performed by calculating the text width using strlen(text) * h_char.
  361.  
  362.  _point(x,y,point)  Called to place a point at position (x,y). point is -1 or 
  363. an integer from 0 upwards. At least 6 point types (numbered 0 to 5) are 
  364. normally provided. Point type -1 is a dot. If point is more than the available 
  365. point types then it should be mapped back to one of the available points. Two 
  366. _point() functions called do_point() and line_and_point() are provided in 
  367. term.c and should be suitable for most drivers. do_point() draws the points in 
  368. the current line type. If your driver uses dotted line types (generally because 
  369. it is monochrome), you should use line_and_point() which changes to line type 0 
  370. before drawing the point.  line type 0 should be solid.
  371.  
  372.  There is a global variable 'pointsize' which is controlled by the set 
  373. pointsize command. If possible, use that. pointsize should be examined at 
  374. terminal init. If it is subsequently changed, the set_pointsize() fn will be called.
  375.  
  376.  _arrow(sx,sy,ex,ey,head)  Called to draw an arrrow from (sx,sy) to (ex,ey). A 
  377. head is drawn on the arrow if head = TRUE. An _arrow() function called 
  378. do_arrow() is provided in term.c which will draw arrows using the _move() and 
  379. _vector() functions. Drivers should use do_arrow unless it causes problems.
  380.  
  381.  _set_font() is called to set the font of labels, etc [new 3.7 feature] fonts 
  382. are selected as strings "name,size"
  383.  
  384.  _pointsize() is used to set the pointsize for subsequent points 
  385.  
  386. _flags stores various flags describing driver capabilities. Currently
  387.  three bits are allocated
  388.   - TERM_CAN_MULTIPLOT - driver can do multiplot
  389.   fully-interactively when output is not redirected. ie text and graphics
  390.   go to different places, or driver can flip using suspend.
  391.   - TERM_CANT_MULTIPLOT - driver cannot multiplot, even if output
  392.   is redirected.
  393.   - TERM_BINARY - output file must be opened in binary mode
  394.   Another bit is earmarked for VMS_PASTHRU, but not yet implemented.
  395.  
  396. _suspend() - called before gnuplot issues a prompt in multiplot mode
  397.    linux vga driver uses this entry point to flip from graphics to
  398.    text mode. X11 driver will take this opportunity to paint the window
  399.    on the display.
  400.  
  401. _resume() - called after suspend(), before subsequent plots of a multiplot. 
  402.  
  403. _boxfill() - fills a box in given style (currently unimplemented - always
  404.            background colour at present). used by 'clear' in multiplot for
  405.            support of inset graphs
  406.  
  407. _linewidth() - sets the linewidth 
  408.  
  409.  The following should illustrate the order in which calls to these routines are 
  410. made: 
  411.  
  412.  _options()
  413.   _init()
  414.     _scale(xs,ys)
  415.     _graphics()
  416.       _linewidth(lw)
  417.       _linetype(lt)
  418.       _move(x,y)
  419.       _vector(x,y)
  420.       _pointsize(size)
  421.       _point(x,y,point)
  422.       _text_angle(angle)
  423.       _justify(mode)
  424.       _set_font(font)
  425.       _put_text(x,y,text)
  426.       _arrow(sx,sy,ex,ey)
  427.     _text()
  428.     _graphics()
  429.       .
  430.     _suspend()
  431.     _set_pointsize()
  432.     _resume()
  433.       .
  434.     _text()
  435.   _reset()
  436.  
  437. ------------------------------------
  438.  
  439.  BITMAP DEVICES 
  440.  
  441.  A file bitmap.c is provided, implementing a generic set of bitmap routines. It 
  442. provides all the routines required to generate a bitmap in memory, drawing 
  443. lines and writing text. A simple driver need provide only a text() entry point, 
  444. which converts and outputs the stored bitmap in the format required by the device.
  445.  
  446.  Internally, the bitmap is built of one or more planes of 1 bit per pixel. In 
  447. fact, I think the library would be easier to use if it offered one or more 
  448. planes of pixels with 1,2,4 or 8 bits per pixel, since not all bitmap devices 
  449. are based on planes, and the planes have to be recombined at the end at 
  450. present. In general, a device would use either planes or bits-per-pixel, though 
  451. I guess a 24-bit bitmap could use 3 planes of 8 bits per pixel..?
  452.  
  453.  The pixels are currently organised horizontally packed into bytes.
  454.  
  455.  ie 
  456.  
  457.   ********%%%%%%%%$$$$$$$$!!!!!!!! etc
  458.   ^^^^^^^^@@@@@@@@########++++++++ etc
  459.  
  460. where like symbols are stored in one byte. Vertical packing can be arranged by 
  461. reversing x and y dimensions and setting the global b_rastermode to TRUE.  (eg 
  462. epson 8-pin dot-matrix printer)
  463.  
  464.  Functions provided are 
  465.  
  466.  (internal fns ? - should probably be static, not external ?) 
  467.  
  468.   b_setpixel(x,y,value)
  469.   b_setmaskpixel(x,y,value)
  470.   b_putc(x,y,char,angle)
  471.   b_setvalue(size)
  472.  
  473. setting up stuff 
  474.  
  475.   b_makebitmap(x,y,planes)  - make a bitmap of size x * y
  476.   b_freebitmap()            - free bitmap
  477.   b_charsize(size)
  478.  
  479. gnuplot driver interface functions  (can go straight into gnuplot structure) 
  480.  
  481.   b_setlinetype(linetype)
  482.   b_move(x,y)
  483.   b_vector(x,y)
  484.   b_put_text(x,y,*str)
  485.   b_text_angle(ang)
  486.  
  487. I think that the library could be made easier to use if we defined a structure 
  488. which described the bitmap (raster mode, planes, bits-per-pixel, colours, etc) 
  489. and then added to the gnuplot term struct a pointer to this structure. Then we 
  490. could have b_graphics() routine which did all the initialisation that presently 
  491. has to be done by the driver graphics() entry point.  Also, one day I would 
  492. like to have parsing, including terminal driver options, table-driven, but I'm 
  493. getting ahead of myself here.
  494.  
  495.  At present, bitmap.c is linked into gnuplot unconditionally. Perhaps it should 
  496. be put into a library, so that it is linked in only if any of the user-selected 
  497. drivers require bitmap support.
  498.  
  499.  There may be scope to do similar things with some of the other stuff that is 
  500. shared by several drivers. Rather than requiring, for example, that LATEX 
  501. driver is required if EMTEX is to be used, the shared routines could be 
  502. extracted to a library and linked if any of the drivers which use them are 
  503. used.  Just a thought...
  504.  
  505.  ------------------------------------
  506.  
  507.  FILE LAYOUT -----------
  508.  
  509.  I think a file layout like the following will leave most flexibility to the 
  510. gnuplot maintainers. I use REGIS for example. 
  511.  
  512.   #include "driver.h"
  513.  
  514.   #ifdef TERM_REGISTER
  515.   register_term(regis) /* no ; */
  516.   #endif
  517.  
  518.   #ifdef TERM_PROTO
  519.   TERM_PUBLIC void REGISinit __PROTO((void));
  520.   TERM_PUBLIC void REGISgraphics __PROTO((void));
  521.   /* etc */
  522.   #define GOT_REGIS_PROTO
  523.   #endif
  524.  
  525.   #ifndef TERM_PROTO_ONLY
  526.   #ifdef TERM_BODY
  527.  
  528.   TERM_PUBLIC void REGISinit()
  529.   {
  530.     /* etc */
  531.   }
  532.  
  533.   /* etc */
  534.  
  535.   #endif
  536.  
  537.   #ifdef TERM_TABLE
  538.  
  539.   TERM_TABLE_START(regis_driver)
  540.     /* no { */
  541.     "regis", "REGIS graphics language",
  542.     REGISXMAX, /* etc */
  543.     /* no } */
  544.   TERM_TABLE_END(regis_driver)
  545.  
  546.   #undef LAST_TERM
  547.   #define LAST_TERM regis_driver
  548.  
  549.   #endif /* TERM_TABLE */
  550.   #endif /* TERM_PROTO_ONLY */
  551.  
  552.   #ifdef TERM_HELP
  553.   START_HELP(regis)
  554.   "1 regis",
  555.   "?set terminal regis",
  556.   "?regis",
  557.   " The `regis` terminal device generates output in the REGIS graphics language.",
  558.   " It has the option of using 4 (the default) or 16 colors.",
  559.   "",
  560.   " Syntax:",
  561.   "         set term regis {4 | 16}"
  562.   END_HELP(regis)
  563.   #endif
  564.  
  565. --------------
  566.  
  567.  The first three lines in the TERM_HELP section must contain the same name as 
  568. that specified by register_term, since this is the name that will be entered 
  569. into the list of available terminals.  If more than one name is registered, the 
  570. additional names should have their own two "?" lines, but not the "1" line.
  571.  
  572.  Each record is enclosed in double-quotes and (except for the last record) 
  573. followed by a comma.  The text is copied as a single string into gnuplot.doc, 
  574. so the syntax must obey the rules of that entity. If the text includes 
  575. double-quotes or backslashes, these must be escaped by preceding each occurence 
  576. with a backslash.
  577.  
  578.  --------------
  579.  
  580.  Rationale:
  581.  
  582.  We may want to compile all drivers into term.c or one driver at a time this 
  583. layout should support both TERM_PUBLIC will be static  if all modules are in 
  584. term.c, or blank otherwise. Please make private support functions static if possible.
  585.  
  586.  We may include term.h, and therefore all these files, one or more times. If 
  587. just once (all modules compiled into term.c) putting the four parts in this 
  588. order should make it work.
  589.  
  590.  we may compile the table entries into either an array or a linked list This 
  591. organisation should support both 
  592.  
  593.  For separate compilation, we may write a program which defines TERM_REGISTER 
  594. and #include term.h to find out which drivers are selected in term.h and 
  595. thereby generate a makefile.
  596.  
  597.  For a driver which depends on another (eg enhpost and pslatex on post) the 
  598. driver can do something like 
  599.  
  600.   #ifndef GOT_POST_PROTO
  601.   #define TERM_PROTO_ONLY
  602.   #include "post.trm"
  603.   #undef TERM_PROTO_ONLY
  604.   #endif
  605.  
  606. this is probably needed only in the TERM_TABLE section only, but may also be 
  607. used in the body. The TERM_PROTO_ONLY means that we pick up only the protos 
  608. from post.trm, even if current driver is being compiled with TERM_BODY or TERM_TABLE
  609.  
  610.  If we do it the linked-list way, the arg to TERM_TABLE_START will be the name 
  611. of the variable, so any valid, unique name is fine. The TERM_TABLE_START macro 
  612. will do all the work of linking the entries together, probably using LAST_TERM
  613.  
  614.  The inclusion of the TERM_HELP section (and removal of terminal documentation 
  615. from the master gnuplot.doc file) means that the online help will include 
  616. discussions of only those terminals available to the user.  For generation of 
  617. the printed manual, all can be included.
  618.  
  619.  Please make as many things as possible static, but do still try to use unique 
  620. names since all drivers may all be compiled into term.o
  621.  
  622.  The bit in the PROTO section is basically what you would put into a .h file if 
  623. we had them - everything that is needed by the TABLE_ENTRY should be defined in 
  624. this part. In particular, dont forget all the maxes and character sizes and 
  625. things for the table entry.
  626.  
  627.  Dont forget to put TERM_PUBLIC in the defns of the fns as well as the 
  628. prototypes. It will probably always expand to 'static' except for pcs.  Go Up 
  629.  
  630.  
  631. ΓòÉΓòÉΓòÉ 2.6. Using Term::Gnuplot from C libraries ΓòÉΓòÉΓòÉ
  632.  
  633. The interface of this module to gnuplot version 3.7 is going via a translation 
  634. layer in Gnuplot.h.  This layer isolates low-level drawing routines from 
  635. gnuplot program.  (In doing this unsupported job it does some nasty thing, in 
  636. particular Gnuplot.h cannot be included in more than one C compilation unit.)
  637.  
  638.  In fact Gnuplot.h can be used by any C program or library which wants to use 
  639. device-independent plotting routines of gnuplot.
  640.  
  641.  C library should use the same syntax of calls as Term::Gnuplot, with the only 
  642. difference that to call low-level _init() method one calls gptable_init(), to 
  643. set terminal one calls termset(name), and to get a property of terminal (say 
  644. xmax) one uses termprop(xmax).
  645.  
  646.  To set options one can setup the array token and data c_token, num_tokens, 
  647. input_line, then call options().  Alternately, one can define 
  648. SET_OPTIONS_FROM_STRING, then a call set_options_from(string) is avalable. 
  649. This call will set up all these variables and will call options().  However, 
  650. the logic of the parsing of the string is very primitive.
  651.  
  652.  NOTES. 
  653.  
  654.      To initialize the facilities of Gnuplot.h from C one needs to call 
  655.       setup_gpshim().  This call can be made as many times as wanted, only the 
  656.       first call will do anything.
  657.  
  658.      NULL argument to term_set_output() means "reset back to stdout".
  659.  
  660.      Gnuplot.h expects that the macro/function croak(...) is defined. This 
  661.       function should have the same syntax as printf(), and should not return. 
  662.       It is used as an error-reporting function.
  663.  
  664.      One should define functions int StartOutput(), int EndOutput() and int 
  665.       OutLine(char *s) which will be used by gnuplot for error messages and for 
  666.       terminal listing.  Alternatively, one can define GNUPLOT_OUTLINE_STDOUT, 
  667.       and gnuplot will put these messages to stdout. 
  668.   Go Up 
  669.  
  670.  
  671. ΓòÉΓòÉΓòÉ 2.6.1. Runtime link with gnuplot DLL ΓòÉΓòÉΓòÉ
  672.  
  673. There are two different ways to use the plotting calls via Gnuplot.h. One can 
  674. either establish the link to gnuplot library at compile/link time, or to 
  675. postpone this link to run time.  By default Gnuplot.h provides the first way, 
  676. to switch to the second way define DYNAMIC_GNUPLOT before including Gnuplot.h.
  677.  
  678.  To establish a link at run time, one needs to load a dynamic library which is 
  679. compiled from Gnuplot.h - but without DYNAMIC_GNUPLOT defined. Feed the result 
  680. of the call to get_term_ftable() as an argument to set_term_ftable(), as in 
  681. (with error-condition checking disabled): 
  682.  
  683.   typedef struct t_ftable *(*g_ftable)(void);
  684.   g_ftable g_ftable_addr;
  685.   void *handle = dlopen("gnuterm.dll", mode);
  686.  
  687.   g_ftable_addr = (g_ftable) dlsym(handle, "get_term_ftable");
  688.   set_term_ftable((*g_ftable_addr)());
  689.  
  690. This means that any C library/program which uses the API provided by Gnuplot.h 
  691. does not need to be even linked with gnuplot, neither it requires include files 
  692. of gnuplot.  If plotting is done in some situations only, one will not need the 
  693. overhead of gnuplot plotting library (gnuterm.dll in the above example) unless 
  694. plotting is requested.  Go Up 
  695.  
  696.  
  697. ΓòÉΓòÉΓòÉ 2.6.2. Runtime link of a Perl module with Term::Gnuplot ΓòÉΓòÉΓòÉ
  698.  
  699. To facilitate run time link the Term::Gnuplot Perl module provides a Perl 
  700. subroutine get_term_ftable() which is a variant of C get_term_ftable() which 
  701. returns an integer instead of an address.  One can feed this integer to a C 
  702. function v_set_term_ftable(void*), which will establish a runtime link.  Thus 
  703. the external XS library which wants to use Term::Gnuplot at runtime can put 
  704. this in .xs file: 
  705.  
  706.   #define int_set_term_ftable(a) (v_set_term_ftable((void*)a))
  707.   extern  void v_set_term_ftable(void *a);
  708.   ...
  709.  
  710.   void
  711.   int_set_term_ftable(a)
  712.     IV a
  713.  
  714. include Gnuplot.h (with DYNAMIC_GNUPLOT defined) into any C file, and define 
  715. this Perl subroutine 
  716.  
  717.   sub link_gnuplot {
  718.     eval 'use Term::Gnuplot 0.56; 1' or die;
  719.     int_set_term_ftable(Term::Gnuplot::get_term_ftable());
  720.   }
  721.  
  722. in .pm file. 
  723.  
  724.  Now if it needs to do plotting, it calls link_gnuplot(), then does the 
  725. plotting - without a need to interact with gnuplot at compile/link time, and 
  726. having the additional burden of low-level plotting code loaded in the executable/DLL.
  727.  
  728.  After a call link_gnuplot(), all the Gnuplot.h API calls made from the above C 
  729. file will be directed through the vtables of the Perl module Term::Gnuplot.  Go 
  730. Up 
  731.  
  732.  
  733. ΓòÉΓòÉΓòÉ 2.6.3. Using different Plotting libraries ΓòÉΓòÉΓòÉ
  734.  
  735. In fact Gnuplot.h knows almost nothing about gnuplot, with a notable exceptions 
  736. that there is an API call term = change_term(name), which returns a table of 
  737. methods.  Thus in principle Gnuplot.h can establish a runtime-link with any 
  738. plotting library which supports (or can be coerced to support) this call.  (The 
  739. table is assumed to be compatible with gnuplot layout of struct termentry.)
  740.  
  741.  Gnuplot.h uses also a handful of other gnuplot APIs (such as changing output 
  742. file and several initialization shortcuts), but they should be easy to be 
  743. ignored if an interface to another plotting library is needed.  Go Up 
  744.  
  745.  
  746. ΓòÉΓòÉΓòÉ 2.7. Examples ΓòÉΓòÉΓòÉ
  747.  
  748. Examples 
  749.  
  750.      High-level plotting 
  751.      Multifile plotting 
  752.   Go Up 
  753.  
  754.  
  755. ΓòÉΓòÉΓòÉ 2.7.1. High-level plotting ΓòÉΓòÉΓòÉ
  756.  
  757.   sub ploth {
  758.     my ($xmin, $xmax, $sub) = (shift, shift, shift);
  759.     my $wpoints = scaled_xmax() - 1;
  760.     my $hpoints = scaled_ymax() - 1;
  761.     my $delta = ($xmax - $xmin)/$wpoints;
  762.     my (@ys, $y);
  763.     my ($ymin, $ymax) = (1e300, -1e300);
  764.     my $x = $xmin;
  765.     for my $i (0 .. $wpoints) {
  766.       $y = $sub->($x);
  767.       push @ys, $y;
  768.       $ymin = $y if $ymin > $y;
  769.       $ymax = $y if $ymax < $y;
  770.       $x += $delta;
  771.     }
  772.     my $deltay = ($ymax - $ymin)/$hpoints;
  773.     $_ = ($_ - $ymin)/$deltay + $yfix for @ys;
  774.  
  775.     term_start_plot();
  776.  
  777.     linetype -2;
  778.     move 0, $yfix;
  779.     vector 0, $hpoints + $yfix;
  780.     vector $wpoints, $hpoints + $yfix;
  781.     vector $wpoints, $yfix;
  782.     vector 0, $yfix;
  783.  
  784.     linetype -1;
  785.     if ($xmin < 0 && $xmax > 0) {
  786.       my $xzero = -$xmin/$delta;
  787.       move $xzero, $yfix;
  788.       vector $xzero, $hpoints + $yfix;
  789.     }
  790.     if ($ymin < 0 && $ymax > 0) {
  791.       my $yzero = -$ymin/$deltay + $yfix;
  792.       move 0, $yzero;
  793.       vector $wpoints, $yzero;
  794.     }
  795.  
  796.     linetype 0;
  797.     move 0, int($ys[0] + 0.5);
  798.     linetype 0;
  799.     for my $i (1 .. $wpoints) {
  800.       $x += $delta;
  801.       vector $i, int($ys[$i] + 0.5);
  802.     }
  803.     term_end_plot();
  804.   }
  805.  
  806. This function should be used as in 
  807.  
  808.   ploth(-1,3, sub { sin( (shift)**6 ) })
  809.  
  810. $yfix should be set to 1 for gif terminal to compensate for off-by-one bug.  Go 
  811. Up 
  812.  
  813.  
  814. ΓòÉΓòÉΓòÉ 2.7.2. Multifile plotting ΓòÉΓòÉΓòÉ
  815.  
  816.   use strict;
  817.   use Term::Gnuplot qw(:ALL);
  818.  
  819.   my ($yfix, $ext) = (1, 'gif');
  820.   plot_outfile_set "manypl1.$ext";              # Need to set before plotterm()
  821.  
  822.   change_term "gif";
  823.   set_options "size", 300, ',', 200;
  824.   term_init();
  825.  
  826.   for my $k (1..6) {
  827.     plot_outfile_set "manypl$k.$ext" unless $k == 1;
  828.     ploth( -1, 3, sub { sin((shift)**$k) } );
  829.   }
  830.  
  831. Here we use the function ploth() from High-level plotting, it should be in the 
  832. same scope so that $yfix is visible there.  Note that gif terminal requires 
  833. $yfix to be 1 to circumvent a bug, and requires a literal ',' in the 
  834. set_options call.
  835.  
  836.  If a terminal does not support direct setting of the size of the output 
  837. device, one may set global rescaling factors by calling plotsizes_scale(): 
  838.  
  839.   plotsizes_scale(300/xmax(), 200/ymax());
  840.  Go Up 
  841.  
  842.  
  843. ΓòÉΓòÉΓòÉ 2.8. BUGS and LIMITATIONS ΓòÉΓòÉΓòÉ
  844.  
  845. The following C macros are set to reasonable values, no peeking is performed to 
  846. get correct values, this may break Gnuplot on some systems: 
  847.  
  848.   NO_ATEXIT HAVE_ON_EXIT PIPES HAVE_LIBC_H
  849.  
  850. No testing for 
  851.  
  852.   X11
  853.  
  854. macros is performed either, however, this may only increase size of the 
  855. executable (since X11 module is not making any direct X calls, but calls an 
  856. external program to serve the requests).
  857.  
  858.  Apparently gif terminal has off-by-one error: yrange is 1..ymax(). All the 
  859. bugs of gnuplot low-level plotting show in this module as well.  Go Up 
  860.  
  861.  
  862. ΓòÉΓòÉΓòÉ 2.9. SEE ALSO ΓòÉΓòÉΓòÉ
  863.  
  864. Term::GnuplotTerminals.  Go Up 
  865.  
  866.  
  867. ΓòÉΓòÉΓòÉ 3. GnuplotTerminals - documentation of gnuplot output devices ΓòÉΓòÉΓòÉ
  868.  
  869. GnuplotTerminals - documentation of gnuplot output devices 
  870.  
  871.      NAME 
  872.      aed767 
  873.      aifm 
  874.      amiga 
  875.      apollo 
  876.      atari ST (via AES) 
  877.      atari ST (via VDI) 
  878.      cgi 
  879.      cgm 
  880.         -  font 
  881.         -  fontsize 
  882.         -  linewidth 
  883.         -  rotate 
  884.         -  solid 
  885.         -  size 
  886.         -  width 
  887.         -  winword6 
  888.      corel 
  889.      debug 
  890.      svga 
  891.      dumb 
  892.      dxf 
  893.      dxy800a 
  894.      eepic 
  895.      emxvga 
  896.      epson-180dpi 
  897.      excl 
  898.      hercules 
  899.      fig 
  900.      gif 
  901.      unixplot 
  902.      gpic 
  903.      gpr 
  904.      grass 
  905.      hp2623a 
  906.      hp2648 
  907.      hp500c 
  908.      hpgl 
  909.      hpljii 
  910.      hppj 
  911.      imagen 
  912.      iris4d 
  913.      kyo 
  914.      latex 
  915.      linux 
  916.      macintosh 
  917.      mf 
  918.         -  METAFONT Instructions 
  919.      mgr 
  920.      mif 
  921.      mtos 
  922.      next 
  923.      pbm 
  924.      dospc 
  925.      pm 
  926.      png 
  927.      postscript 
  928.         -  enhanced postscript 
  929.         -  editing postscript 
  930.      pslatex and pstex 
  931.      pstricks 
  932.      qms 
  933.      regis 
  934.      rgip 
  935.      sun 
  936.      tek410x 
  937.      table 
  938.      tek40 
  939.      texdraw 
  940.      tgif 
  941.      tkcanvas 
  942.      tpic 
  943.      unixpc 
  944.      unixplot 
  945.      vx384 
  946.      VWS 
  947.      windows 
  948.         -  graph-menu 
  949.         -  printing 
  950.         -  text-menu 
  951.         -  wgnuplot.ini 
  952.         -  windows3.0 
  953.      x11 
  954.         -  command-line_options 
  955.         -  monochome_options 
  956.         -  color_resources 
  957.         -  grayscale_resources 
  958.         -  line_resources 
  959.      xlib 
  960.      AUTHOR 
  961.      SEE ALSO 
  962.  
  963.  
  964. ΓòÉΓòÉΓòÉ 3.1. NAME ΓòÉΓòÉΓòÉ
  965.  
  966. Term::GnuplotTerminals - documentation of gnuplot output devices  Go Up 
  967.  
  968.  
  969. ΓòÉΓòÉΓòÉ 3.2. aed767 ΓòÉΓòÉΓòÉ
  970.  
  971. The aed512 and aed767 terminal drivers support AED graphics terminals. The two 
  972. drivers differ only in their horizontal ranges, which are 512 and 768 pixels, 
  973. respectively.  Their vertical range is 575 pixels.  There are no options for 
  974. these drivers.  Go Up 
  975.  
  976.  
  977. ΓòÉΓòÉΓòÉ 3.3. aifm ΓòÉΓòÉΓòÉ
  978.  
  979. Several options may be set in aifm---the Adobe Illustrator 3.0+ driver.
  980.  
  981.  Syntax: 
  982.  
  983.       set terminal aifm {<color>} {"<fontname>"} {<fontsize>}
  984.  
  985. <color> is either color or monochrome; "<fontname>" is the name of a valid 
  986. PostScript font; <fontsize> is the size of the font in PostScript points, 
  987. before scaling by the set size command.  Selecting default sets all options to 
  988. their default values: monochrome, "Helvetica", and 14pt.
  989.  
  990.  Since AI does not really support multiple pages, multiple graphs will be drawn 
  991. directly on top of one another.  However, each graph will be grouped 
  992. individually, making it easy to separate them inside AI (just pick them up and 
  993. move them).
  994.  
  995.  Examples: 
  996.  
  997.       set term aifm
  998.       set term aifm 22
  999.       set size 0.7,1.4; set term aifm color "Times-Roman" 14
  1000.  Go Up 
  1001.  
  1002.  
  1003. ΓòÉΓòÉΓòÉ 3.4. amiga ΓòÉΓòÉΓòÉ
  1004.  
  1005. The amiga terminal, for Commodore Amiga computers, allows the user to plot 
  1006. either to a screen (default), or, if Kickstart 3.0 or higher is installed, to a 
  1007. window on the current public screen. The font and its size can also be selected.
  1008.  
  1009.  Syntax: 
  1010.  
  1011.       set terminal amiga {screen | window} {"<fontname>"} {<fontsize>}
  1012.  
  1013. The default font is 8-point "topaz".
  1014.  
  1015.  The screen option uses a virtual screen, so it is possible that the graph will 
  1016. be larger than the screen.  Go Up 
  1017.  
  1018.  
  1019. ΓòÉΓòÉΓòÉ 3.5. apollo ΓòÉΓòÉΓòÉ
  1020.  
  1021. The apollo terminal driver supports the Apollo Graphics Primitive Resource with 
  1022. rescaling after window resizing.  It has no options.
  1023.  
  1024.  If a fixed-size window is desired, the gpr terminal may be used instead.  Go 
  1025. Up 
  1026.  
  1027.  
  1028. ΓòÉΓòÉΓòÉ 3.6. atari ST (via AES) ΓòÉΓòÉΓòÉ
  1029.  
  1030. The atari terminal has options to set the character size and the screen colors.
  1031.  
  1032.  Syntax: 
  1033.  
  1034.       set terminal atari {<fontsize>} {<col0> <col1> ... <col15.}
  1035.  
  1036. The character size must appear if any colors are to be specified.  Each of the 
  1037. (up to 16) colors is given as a three-digit hex number, where the digits 
  1038. represent RED, GREEN and BLUE (in that order).  The range of 0--15 is scaled to 
  1039. whatever color range the screen actually has.  On a normal ST screen, odd and 
  1040. even intensities are the same.
  1041.  
  1042.  Examples: 
  1043.  
  1044.       set terminal atari 4    # use small (6x6) font
  1045.       set terminal atari 6 0  # set monochrome screen to white on black
  1046.       set terminal atari 13 0 fff f00 f0 f ff f0f
  1047.                  # set first seven colors to black, white, green, blue,
  1048.                  # cyan, purple, and yellow and use large font (8x16).
  1049.  
  1050. Additionally, if an environment variable GNUCOLORS exists, its contents are 
  1051. interpreted as an options string, but an explicit terminal option takes 
  1052. precedence.  Go Up 
  1053.  
  1054.  
  1055. ΓòÉΓòÉΓòÉ 3.7. atari ST (via VDI) ΓòÉΓòÉΓòÉ
  1056.  
  1057. The vdi terminal is the same as the atari terminal, except that it sends output 
  1058. to the screen via the VDI and not into AES-Windows.
  1059.  
  1060.  The vdi terminal has options to set the character size and the screen colors.
  1061.  
  1062.  Syntax: 
  1063.  
  1064.       set terminal vdi {<fontsize>} {<col0> <col1> ... <col15.}
  1065.  
  1066. The character size must appear if any colors are to be specified.  Each of the 
  1067. (up to 16) colors is given as a three-digit hex number, where the digits 
  1068. represent RED, GREEN and BLUE (in that order).  The range of 0--15 is scaled to 
  1069. whatever color range the screen actually has.  On a normal ST screen, odd and 
  1070. even intensities are the same.
  1071.  
  1072.  Examples: 
  1073.  
  1074.       set terminal vdi 4    # use small (6x6) font
  1075.       set terminal vdi 6 0  # set monochrome screen to white on black
  1076.       set terminal vdi 13 0 fff f00 f0 f ff f0f
  1077.                  # set first seven colors to black, white, green, blue,
  1078.                  # cyan, purple, and yellow and use large font (8x16).
  1079.  
  1080. Additionally, if an environment variable GNUCOLORS exists, its contents are 
  1081. interpreted as an options string, but an explicit terminal option takes 
  1082. precedence.  Go Up 
  1083.  
  1084.  
  1085. ΓòÉΓòÉΓòÉ 3.8. cgi ΓòÉΓòÉΓòÉ
  1086.  
  1087. The cgi and hcgi terminal drivers support SCO CGI drivers.  hcgi is for 
  1088. printers; the environment variable CGIPRNT must be set.  cgi may be used for 
  1089. either a display or hardcopy; if the environment variable CGIDISP is set, then 
  1090. that display is used.  Otherwise CGIPRNT is used.
  1091.  
  1092.  These terminals have no options.  Go Up 
  1093.  
  1094.  
  1095. ΓòÉΓòÉΓòÉ 3.9. cgm ΓòÉΓòÉΓòÉ
  1096.  
  1097. The cgm terminal generates a Computer Graphics Metafile.  This file format is a 
  1098. subset of the ANSI X3.122-1986 standard entitled "Computer Graphics - Metafile 
  1099. for the Storage and Transfer of Picture Description Information". Several 
  1100. options may be set in cgm.
  1101.  
  1102.  Syntax: 
  1103.  
  1104.       set terminal cgm {<mode>} {<color>} {<rotation>} {solid | dashed}
  1105.                        {width <plot_width>} {linewidth <line_width>}
  1106.                        {"<font>"} {<fontsize>}
  1107.  
  1108. where <mode> is landscape, portrait, or default; <color> is either color or 
  1109. monochrome; <rotation> is either rotate or norotate; solid draws all curves 
  1110. with solid lines, overriding any dashed patterns; <plot_width> is the width of 
  1111. the page in points; <line_width> is the line width in points; <font> is the 
  1112. name of a font; and <fontsize> is the size of the font in points.
  1113.  
  1114.  By default, cgm uses rotated text for the Y axis label.
  1115.  
  1116.  The first six options can be in any order.  Selecting default sets all options 
  1117. to their default values.
  1118.  
  1119.  Examples: 
  1120.  
  1121.       set terminal cgm landscape color rotate dashed width 432 \
  1122.                      linewidth 1  'Arial Bold' 12       # defaults
  1123.       set terminal cgm 14 linewidth 2  14  # wider lines & larger font
  1124.       set terminal cgm portrait 'Times Roman Italic' 12
  1125.       set terminal cgm color solid    # no pesky dashes!
  1126.  Go Up 
  1127.  
  1128.  
  1129. ΓòÉΓòÉΓòÉ 3.9.1. font ΓòÉΓòÉΓòÉ
  1130.  
  1131. The first part of a Computer Graphics Metafile, the metafile description, 
  1132. includes a font table.  In the picture body, a font is designated by an index 
  1133. into this table.  By default, this terminal generates a table with the 
  1134. following fonts: 
  1135.  
  1136.        Arial
  1137.        Arial Italic
  1138.        Arial Bold
  1139.        Arial Bold Italic
  1140.        Times Roman
  1141.        Times Roman Italic
  1142.        Times Roman Bold
  1143.        Times Roman Bold Italic
  1144.        Helvetica
  1145.        Roman
  1146.  
  1147. Case is not distinct, but the modifiers must appear in the above order (that 
  1148. is, not 'Arial Italic Bold').  'Arial Bold' is the default font.
  1149.  
  1150.  You may also specify a font name which does not appear in the default font 
  1151. table.  In that case, a new font table is constructed with the specified font 
  1152. as its only entry.  You must ensure that the spelling, capitalization, and 
  1153. spacing of the name are appropriate for the application that will read the CGM 
  1154. file.  Go Up 
  1155.  
  1156.  
  1157. ΓòÉΓòÉΓòÉ 3.9.2. fontsize ΓòÉΓòÉΓòÉ
  1158.  
  1159. Fonts are scaled assuming the page is 6 inches wide.  If the size command is 
  1160. used to change the aspect ratio of the page or the CGM file is converted to a 
  1161. different width (e.g. it is imported into a document in which the margins are 
  1162. not 6 inches apart), the resulting font sizes will be different. To change the 
  1163. assumed width, use the width option.  Go Up 
  1164.  
  1165.  
  1166. ΓòÉΓòÉΓòÉ 3.9.3. linewidth ΓòÉΓòÉΓòÉ
  1167.  
  1168. The linewidth option sets the width of lines in pt.  The default width is 1 pt. 
  1169. Scaling is affected by the actual width of the page, as discussed under the 
  1170. fontsize and width options  Go Up 
  1171.  
  1172.  
  1173. ΓòÉΓòÉΓòÉ 3.9.4. rotate ΓòÉΓòÉΓòÉ
  1174.  
  1175. The norotate option may be used to disable text rotation.  For example, the CGM 
  1176. input filter for Word for Windows 6.0c can accept rotated text, but the DRAW 
  1177. editor within Word cannot.  If you edit a graph (for example, to label a 
  1178. curve), all rotated text is restored to horizontal.  The Y axis label will then 
  1179. extend beyond the clip boundary.  With norotate, the Y axis label starts in a 
  1180. less attractive location, but the page can be edited without damage.  The 
  1181. rotate option confirms the default behavior.  Go Up 
  1182.  
  1183.  
  1184. ΓòÉΓòÉΓòÉ 3.9.5. solid ΓòÉΓòÉΓòÉ
  1185.  
  1186. The solid option may be used to disable dashed line styles in the plots.  This 
  1187. is useful when color is enabled and the dashing of the lines detracts from the 
  1188. appearance of the plot. The dashed option confirms the default behavior, which 
  1189. gives a different dash pattern to each curve.  Go Up 
  1190.  
  1191.  
  1192. ΓòÉΓòÉΓòÉ 3.9.6. size ΓòÉΓòÉΓòÉ
  1193.  
  1194. Default size of a CGM page is 32599 units wide and 23457 units high for 
  1195. landscape, or 23457 units wide by 32599 units high for portrait.  Go Up 
  1196.  
  1197.  
  1198. ΓòÉΓòÉΓòÉ 3.9.7. width ΓòÉΓòÉΓòÉ
  1199.  
  1200. All distances in the CGM file are in abstract units.  The application that 
  1201. reads the file determines the size of the final page.  By default, the width of 
  1202. the final page is assumed to be 6 inches (15.24 cm).  This distance is used to 
  1203. calculate the correct font size, and may be changed with the width option.  The 
  1204. keyword should be followed by the width in points.  (Here, a point is 1/72 
  1205. inch, as in PostScript.  This unit is known as a "big point" in TeX.)  gnuplot 
  1206. arithmetic can be used to convert from other units, as follows: 
  1207.  
  1208.       set terminal cgm width 432            # default
  1209.       set terminal cgm width 6*72           # same as above
  1210.       set terminal cgm width 10/2.54*72     # 10 cm wide
  1211.  Go Up 
  1212.  
  1213.  
  1214. ΓòÉΓòÉΓòÉ 3.9.8. winword6 ΓòÉΓòÉΓòÉ
  1215.  
  1216. The default font table was chosen to match, where possible, the default font 
  1217. assignments made by the Computer Graphics Metafile input filter for Microsoft 
  1218. Word 6.0c, although the filter makes available only 'Arial' and 'Times Roman' 
  1219. fonts and their bold and/or italic variants.  Other fonts such as 'Helvetica' 
  1220. and 'Roman' are not available.  If the CGM file includes a font table, the 
  1221. filter mostly ignores it.  However, it changes certain font assignments so that 
  1222. they disagree with the table.  As a workaround, the winword6 option deletes the 
  1223. font table from the CGM file.  In this case, the filter makes predictable font 
  1224. assignments.  'Arial Bold' is correctly assigned even with the font table 
  1225. present, which is one reason it was chosen as the default.
  1226.  
  1227.  winword6 disables the color tables for a similar reason---with the color table 
  1228. included, Microsoft Word displays black for color 7.
  1229.  
  1230.  Linewidths and pointsizes may be changed with set linestyle.  Go Up 
  1231.  
  1232.  
  1233. ΓòÉΓòÉΓòÉ 3.10. corel ΓòÉΓòÉΓòÉ
  1234.  
  1235. The corel terminal driver supports CorelDraw.
  1236.  
  1237.  Syntax: 
  1238.  
  1239.       set terminal corel {  default
  1240.                           | {monochrome | color
  1241.                                {<fontname> {"<fontsize>"
  1242.                                   {<xsize> <ysize> {<linewidth> }}}}}
  1243.  
  1244. where the fontsize and linewidth are specified in points and the sizes in 
  1245. inches.  The defaults are monochrome, "SwitzerlandLight", 22, 8.2, 10 and 1.2. 
  1246. Go Up 
  1247.  
  1248.  
  1249. ΓòÉΓòÉΓòÉ 3.11. debug ΓòÉΓòÉΓòÉ
  1250.  
  1251. This terminal is provided to allow for the debugging of gnuplot.  It is likely 
  1252. to be of use only for users who are modifying the source code.  Go Up 
  1253.  
  1254.  
  1255. ΓòÉΓòÉΓòÉ 3.12. svga ΓòÉΓòÉΓòÉ
  1256.  
  1257. The svga terminal driver supports PCs with SVGA graphics.  It can only be be 
  1258. used if it is compiled with DJGPP.  Its only option is the font.
  1259.  
  1260.  Syntax: 
  1261.  
  1262.       set terminal svga {"<fontname>"}
  1263.  Go Up 
  1264.  
  1265.  
  1266. ΓòÉΓòÉΓòÉ 3.13. dumb ΓòÉΓòÉΓòÉ
  1267.  
  1268. The dumb terminal driver has an optional size specification and trailing 
  1269. linefeed control.
  1270.  
  1271.  Syntax: 
  1272.  
  1273.       set terminal dumb {[no]feed} {<xsize> <ysize>}
  1274.  
  1275. where <xsize> and <ysize> set the size of the dumb terminals. Default is 79 by 
  1276. 24. The last newline is printed only if feed is enabled.
  1277.  
  1278.  Examples: 
  1279.  
  1280.       set term dumb nofeed
  1281.       set term dumb 79 49 # VGA screen---why would anyone do that?
  1282.  Go Up 
  1283.  
  1284.  
  1285. ΓòÉΓòÉΓòÉ 3.14. dxf ΓòÉΓòÉΓòÉ
  1286.  
  1287. The dxf terminal driver creates pictures that can be imported into AutoCad 
  1288. (Release 10.x).  It has no options of its own, but some features of its plots 
  1289. may be modified by other means.  The default size is 120x80 AutoCad units, 
  1290. which can be changed by set size.  dxf uses seven colors (white, red, yellow, 
  1291. green, cyan, blue and magenta), which can be changed only by modifying the 
  1292. source file.  If a black-and-white plotting device is used, the colors are 
  1293. mapped to differing line thicknesses.  See the description of the AutoCad 
  1294. print/plot command.  Go Up 
  1295.  
  1296.  
  1297. ΓòÉΓòÉΓòÉ 3.15. dxy800a ΓòÉΓòÉΓòÉ
  1298.  
  1299. This terminal driver supports the Roland DXY800A plotter.  It has no options. 
  1300. Go Up 
  1301.  
  1302.  
  1303. ΓòÉΓòÉΓòÉ 3.16. eepic ΓòÉΓòÉΓòÉ
  1304.  
  1305. The eepic terminal driver supports the extended LaTeX picture environment. It 
  1306. is an alternative to the latex driver.
  1307.  
  1308.  The output of this terminal is intended for use with the "eepic.sty" macro 
  1309. package for LaTeX.  To use it, you need "eepic.sty", "epic.sty" and a printer 
  1310. driver that supports the "tpic" \specials.  If your printer driver doesn't 
  1311. support those \specials, "eepicemu.sty" will enable you to use some of them.
  1312.  
  1313.  Although dotted and dashed lines are possible with eepic and are tempting, 
  1314. they do not work well for high-sample-rate curves, fusing the dashes all 
  1315. together into a solid line.  For now, the eepic driver creates only solid 
  1316. lines.  There is another gnuplot driver (tpic) that supports dashed lines, but 
  1317. it cannot be used if your DVI driver doesn't support "tpic" \specials.
  1318.  
  1319.  All drivers for LaTeX offer a special way of controlling text positioning: If 
  1320. any text string begins with '{', you also need to include a '}' at the end of 
  1321. the text, and the whole text will be centered both horizontally and vertically 
  1322. by LaTeX. --- If the text string begins with '[', you need to continue it with: 
  1323. a position specification (up to two out of t,b,l,r), ']{', the text itself, and 
  1324. finally, '}'. The text itself may be anything LaTeX can typeset as an LR-box. 
  1325. \rule{}{}'s may help for best positioning.
  1326.  
  1327.  The eepic terminal has no options.
  1328.  
  1329.  Examples: About label positioning: Use gnuplot defaults (mostly sensible, but 
  1330. sometimes not really best): 
  1331.  
  1332.        set title '\LaTeX\ -- $ \gamma $'
  1333.  
  1334. Force centering both horizontally and vertically: 
  1335.  
  1336.        set label '{\LaTeX\ -- $ \gamma $}' at 0,0
  1337.  
  1338. Specify own positioning (top here): 
  1339.  
  1340.        set xlabel '[t]{\LaTeX\ -- $ \gamma $}'
  1341.  
  1342. The other label -- account for long ticlabels: 
  1343.  
  1344.        set ylabel '[r]{\LaTeX\ -- $ \gamma $\rule{7mm}{0pt}'
  1345.  Go Up 
  1346.  
  1347.  
  1348. ΓòÉΓòÉΓòÉ 3.17. emxvga ΓòÉΓòÉΓòÉ
  1349.  
  1350. The emxvga, emxvesa and vgal terminal drivers support PCs with SVGA, vesa SVGA 
  1351. and VGA graphics boards, respectively.  They are intended to be compiled with 
  1352. "emx-gcc" under either DOS or OS/2.  They also need VESA and SVGAKIT maintained 
  1353. by Johannes Martin (JMARTIN@GOOFY.ZDV.UNI-MAINZ.DE) with additions by David J. 
  1354. Liu (liu@phri.nyu.edu).
  1355.  
  1356.  Syntax: 
  1357.  
  1358.       set terminal emxvga
  1359.       set terminal emxvesa {vesa-mode}
  1360.       set terminal vgal
  1361.  
  1362. The only option is the vesa mode for emxvesa, which defaults to G640x480x256. 
  1363. Go Up 
  1364.  
  1365.  
  1366. ΓòÉΓòÉΓòÉ 3.18. epson-180dpi ΓòÉΓòÉΓòÉ
  1367.  
  1368. This driver supports a family of Epson printers and derivatives.
  1369.  
  1370.  epson-180dpi and epson-60dpi are drivers for Epson LQ-style 24-pin printers 
  1371. with resolutions of 180 and 60 dots per inch, respectively.
  1372.  
  1373.  epson-lx800 is a generic 9-pin driver appropriate for printers like the Epson 
  1374. LX-800, the Star NL-10 and NX-1000, the PROPRINTER, and so forth.
  1375.  
  1376.  nec-cp6 is generix 24-pin driver that can be used for printers like the NEC 
  1377. CP6 and the Epson LQ-800.
  1378.  
  1379.  The okidata driver supports the 9-pin OKIDATA 320/321 Standard printers.
  1380.  
  1381.  The starc driver is for the Star Color Printer.
  1382.  
  1383.  The tandy-60dpi driver is for the Tandy DMP-130 series of 9-pin, 60-dpi printers.
  1384.  
  1385.  Only nec-cp6 has any options.
  1386.  
  1387.  Syntax: 
  1388.  
  1389.       set terminal nec-cp6 {monochrome | colour | draft}
  1390.  
  1391. which defaults to monochrome.
  1392.  
  1393.  With each of these drivers, a binary copy is required on a PC to print.  Do 
  1394. not use print---use instead copy file /b lpt1:.  Go Up 
  1395.  
  1396.  
  1397. ΓòÉΓòÉΓòÉ 3.19. excl ΓòÉΓòÉΓòÉ
  1398.  
  1399. The excl terminal driver supports Talaris printers such as the EXCL Laser 
  1400. printer and the 1590.  It has no options.  Go Up 
  1401.  
  1402.  
  1403. ΓòÉΓòÉΓòÉ 3.20. hercules ΓòÉΓòÉΓòÉ
  1404.  
  1405. These drivers supports PC monitors with autodetected graphics boards.  They can 
  1406. be used only when compiled with Zortech C/C++.  None have options.  Go Up 
  1407.  
  1408.  
  1409. ΓòÉΓòÉΓòÉ 3.21. fig ΓòÉΓòÉΓòÉ
  1410.  
  1411. The fig terminal device generates output in the Fig graphics language.
  1412.  
  1413.  Syntax: 
  1414.  
  1415.       set terminal fig {monochrome | color} {small | big}
  1416.                        {pointsmax <max_points>}
  1417.                        {landscape | portrait}
  1418.                        {metric | inches}
  1419.                        {fontsize <fsize>}
  1420.                        {size <xsize> <ysize>}
  1421.                        {thickness <units>}
  1422.                        {depth <layer>}
  1423.  
  1424. monochrome and color determine whether the picture is black-and-white or color. 
  1425. small and big produce a 5x3 or 8x5 inch graph in the default landscape mode and 
  1426. 3x5 or 5x8 inches in portrait mode.  <max_points> sets the maximum number of 
  1427. points per polyline.  Default units for editing with "xfig" may be metric or 
  1428. inches.  fontsize sets the size of the text font to <fsize> points.  size sets 
  1429. (overrides) the size of the drawing area to <xsize>*<ysize> in units of inches 
  1430. or centimeters depending on the inches or metric setting in effect.  depth sets 
  1431. the default depth layer for all lines and text.  The default depth is 10 to 
  1432. leave room for adding material with "xfig" on top of the plot.
  1433.  
  1434.  thickness sets the default line thickness, which is 1 if not specified. 
  1435. Overriding the thickness can be achieved by adding a multiple of 100 to the to 
  1436. the linetype value for a plot command.  In a similar way the depth of plot 
  1437. elements (with respect to the default depth) can be controlled by adding a 
  1438. multiple of 1000 to <linetype>.  The depth is then <layer> + <linetype>/1000 
  1439. and the thickness is (<linetype>%1000)/100 or, if that is zero, the default 
  1440. line thickness.
  1441.  
  1442.  Additional point-plot symbols are also available with the fig driver. The 
  1443. symbols can be used through pointtype values % 100 above 50, with different 
  1444. fill intensities controlled by <pointtype> % 5 and outlines in black (for 
  1445. <pointtype> % 10 < 5) or in the current color.  Available symbols are 
  1446.  
  1447.         50 - 59:  circles
  1448.         60 - 69:  squares
  1449.         70 - 79:  diamonds
  1450.         80 - 89:  upwards triangles
  1451.         90 - 99:  downwards triangles
  1452.  
  1453. The size of these symbols is linked to the font size.  The depth of symbols is 
  1454. by default one less than the depth for lines to achieve nice error bars. If 
  1455. <pointtype> is above 1000, the depth is <layer> + <pointtype>/1000-1.  If 
  1456. <pointtype>%1000 is above 100, the fill color is (<pointtype>%1000)/100-1.
  1457.  
  1458.  Available fill colors are (from 1 to 9): black, blue, green, cyan, red, 
  1459. magenta, yellow, white and dark blue (in monochrome mode: black for 1 to 6 and 
  1460. white for 7 to 9).
  1461.  
  1462.  See plot with for details of <linetype> and <pointtype>.
  1463.  
  1464.  The big option is a substitute for the bfig terminal in earlier versions, 
  1465. which is no longer supported.
  1466.  
  1467.  Examples: 
  1468.  
  1469.       set terminal fig monochrome small pointsmax 1000  # defaults
  1470.  
  1471.       plot 'file.dat' with points linetype 102 pointtype 759
  1472.  
  1473. would produce circles with a blue outline of width 1 and yellow fill color. 
  1474.  
  1475.       plot 'file.dat' using 1:2:3 with err linetype 1 pointtype 554
  1476.  
  1477. would produce errorbars with black lines and circles filled red.  These circles 
  1478. are one layer above the lines (at depth 9 by default).
  1479.  
  1480.  To plot the error bars on top of the circles use 
  1481.  
  1482.       plot 'file.dat' using 1:2:3 with err linetype 1 pointtype 2554
  1483.  Go Up 
  1484.  
  1485.  
  1486. ΓòÉΓòÉΓòÉ 3.22. gif ΓòÉΓòÉΓòÉ
  1487.  
  1488. The gif terminal driver generates output in GIF format.  It uses Thomas 
  1489. Boutell's gd library, which is available from http://www.boutell.com/gd/
  1490.  
  1491.  Syntax: 
  1492.  
  1493.       set terminal gif {transparent} {interlace}
  1494.                        {small | medium | large}
  1495.                        {size <x>,<y>}
  1496.                        {<color0> <color1> <color2> ...}
  1497.  
  1498. transparent instructs the driver to generate transparent GIFs.  The first color 
  1499. will be the transparent one.
  1500.  
  1501.  interlace instructs the driver to generate interlaced GIFs.
  1502.  
  1503.  The choice of fonts is small (6x12 pixels), medium (7x13 Bold) or large (8x16).
  1504.  
  1505.  The size <x,y> is given in pixels---it defaults to 640x480.  The number of 
  1506. pixels can be also modified by scaling with the set size command.
  1507.  
  1508.  Each color must be of the form 'xrrggbb', where x is the literal character 'x' 
  1509. and 'rrggbb' are the red, green and blue components in hex.  For example, 
  1510. 'x00ff00' is green.  The background color is set first, then the border colors, 
  1511. then the X & Y axis colors, then the plotting colors.  The maximum number of 
  1512. colors that can be set is 256.
  1513.  
  1514.  Examples: 
  1515.  
  1516.       set terminal gif small size 640,480 \
  1517.                        xffffff x000000 x404040 \
  1518.                        xff0000 xffa500 x66cdaa xcdb5cd \
  1519.                        xadd8e6 x0000ff xdda0dd x9500d3    # defaults
  1520.  
  1521. which uses white for the non-transparent background, black for borders, gray 
  1522. for the axes, and red, orange, medium aquamarine, thistle 3, light blue, blue, 
  1523. plum and dark violet for eight plotting colors. 
  1524.  
  1525.       set terminal gif transparent xffffff \
  1526.                        x000000 x202020 x404040 x606060 \
  1527.                        x808080 xA0A0A0 xC0C0C0 xE0E0E0 \
  1528.  
  1529. which uses white for the transparent background, black for borders, dark gray 
  1530. for axes, and a gray-scale for the six plotting colors.
  1531.  
  1532.  The page size is 640x480 pixels.  The gif driver can create either color or 
  1533. monochromatic output, but you have no control over which is produced.
  1534.  
  1535.  The current version of the gif driver does not support animated GIFs.  Go Up 
  1536.  
  1537.  
  1538. ΓòÉΓòÉΓòÉ 3.23. unixplot ΓòÉΓòÉΓòÉ
  1539.  
  1540. The unixplot driver produces device-independent output in the GNU plot graphics 
  1541. language.  The default size of the PostScript results generated by "plot2ps" is 
  1542. 5 x 3 inches; this can be increased up to about 8.25 x 8.25 by set size.
  1543.  
  1544.  Syntax: 
  1545.  
  1546.       set terminal unixplot {"<fontname>"} {<fontsize>}
  1547.  
  1548. which defaults to 10-point "Courier".
  1549.  
  1550.  There is a non-GNU version of the unixplot driver which cannot be compiled 
  1551. unless this version is left out.  Go Up 
  1552.  
  1553.  
  1554. ΓòÉΓòÉΓòÉ 3.24. gpic ΓòÉΓòÉΓòÉ
  1555.  
  1556. The gpic terminal driver generates GPIC graphs in the Free Software 
  1557. Foundations's "groff" package.  The default size is 5 x 3 inches.  The only 
  1558. option is the origin, which defaults to (0,0).
  1559.  
  1560.  Syntax: 
  1561.  
  1562.       set terminal gpic {<x> <y>}
  1563.  
  1564. where x and y are in inches.
  1565.  
  1566.  A simple graph can be formatted using 
  1567.  
  1568.       groff -p -mpic -Tps file.pic > file.ps.
  1569.  
  1570. The output from pic can be pipe-lined into eqn, so it is possible to put 
  1571. complex functions in a graph with the set label and set {x/y}label commands. 
  1572. For instance, 
  1573.  
  1574.       set ylab '@space 0 int from 0 to x alpha ( t ) roman d t@'
  1575.  
  1576. will label the y axis with a nice integral if formatted with the command: 
  1577.  
  1578.       gpic filename.pic | geqn -d@@ -Tps | groff -m[macro-package] -Tps
  1579.           > filename.ps
  1580.  
  1581. Figures made this way can be scaled to fit into a document.  The pic language 
  1582. is easy to understand, so the graphs can be edited by hand if need be.  All 
  1583. co-ordinates in the pic-file produced by gnuplot are given as x+gnuplotx and 
  1584. y+gnuploty.  By default x and y are given the value 0.  If this line is removed 
  1585. with an editor in a number of files, one can put several graphs in one figure 
  1586. like this (default size is 5.0x3.0 inches): 
  1587.  
  1588.       .PS 8.0
  1589.       x=0;y=3
  1590.       copy "figa.pic"
  1591.       x=5;y=3
  1592.       copy "figb.pic"
  1593.       x=0;y=0
  1594.       copy "figc.pic"
  1595.       x=5;y=0
  1596.       copy "figd.pic"
  1597.       .PE
  1598.  
  1599. This will produce an 8-inch-wide figure with four graphs in two rows on top of 
  1600. each other.
  1601.  
  1602.  One can also achieve the same thing by the command 
  1603.  
  1604.       set terminal gpic x y
  1605.  
  1606. for example, using 
  1607.  
  1608.       .PS 6.0
  1609.       copy "trig.pic"
  1610.       .PE
  1611.  Go Up 
  1612.  
  1613.  
  1614. ΓòÉΓòÉΓòÉ 3.25. gpr ΓòÉΓòÉΓòÉ
  1615.  
  1616. The gpr terminal driver supports the Apollo Graphics Primitive Resource for a 
  1617. fixed-size window.  It has no options.
  1618.  
  1619.  If a variable window size is desired, use the apollo terminal instead.  Go Up 
  1620.  
  1621.  
  1622. ΓòÉΓòÉΓòÉ 3.26. grass ΓòÉΓòÉΓòÉ
  1623.  
  1624. The grass terminal driver gives gnuplot capabilities to users of the GRASS 
  1625. geographic information system.  Contact grassp-list@moon.cecer.army.mil for 
  1626. more information.  Pages are written to the current frame of the GRASS Graphics 
  1627. Window.  There are no options.  Go Up 
  1628.  
  1629.  
  1630. ΓòÉΓòÉΓòÉ 3.27. hp2623a ΓòÉΓòÉΓòÉ
  1631.  
  1632. The hp2623a terminal driver supports the Hewlett Packard HP2623A.  It has no 
  1633. options.  Go Up 
  1634.  
  1635.  
  1636. ΓòÉΓòÉΓòÉ 3.28. hp2648 ΓòÉΓòÉΓòÉ
  1637.  
  1638. The hp2648 terminal driver supports the Hewlett Packard HP2647 and HP2648. It 
  1639. has no options.  Go Up 
  1640.  
  1641.  
  1642. ΓòÉΓòÉΓòÉ 3.29. hp500c ΓòÉΓòÉΓòÉ
  1643.  
  1644. The hp500c terminal driver supports the Hewlett Packard HP DeskJet 500c. It has 
  1645. options for resolution and compression.
  1646.  
  1647.  Syntax: 
  1648.  
  1649.       set terminal hp500c {<res>} {<comp>}
  1650.  
  1651. where res can be 75, 100, 150 or 300 dots per inch and comp can be "rle", or 
  1652. "tiff".  Any other inputs are replaced by the defaults, which are 75 dpi and no 
  1653. compression.  Rasterization at the higher resolutions may require a large 
  1654. amount of memory.  Go Up 
  1655.  
  1656.  
  1657. ΓòÉΓòÉΓòÉ 3.30. hpgl ΓòÉΓòÉΓòÉ
  1658.  
  1659. The hpgl driver produces HPGL output for devices like the HP7475A plotter. 
  1660. There are two options which can be set---the number of pens and "eject", which 
  1661. tells the plotter to eject a page when done.  The default is to use 6 pens and 
  1662. not to eject the page when done.
  1663.  
  1664.  The international character sets ISO-8859-1 and CP850 are recognized via set 
  1665. encoding iso_8859_1 or set encoding cp850 (see set encoding for details).
  1666.  
  1667.  Syntax: 
  1668.  
  1669.       set terminal hpgl {<number_of_pens>} {eject}
  1670.  
  1671. The selection 
  1672.  
  1673.       set terminal hpgl 8 eject
  1674.  
  1675. is equivalent to the previous hp7550 terminal, and the selection 
  1676.  
  1677.       set terminal hpgl 4
  1678.  
  1679. is equivalent to the previous hp7580b terminal.
  1680.  
  1681.  The pcl5 driver supports the Hewlett-Packard Laserjet III.  It actually uses 
  1682. HPGL-2, but there is a name conflict among the terminal devices.  It has 
  1683. several options 
  1684.  
  1685.  Syntax: 
  1686.  
  1687.       set terminal pcl5 {<mode>} {<font>} {<fontsize>}
  1688.  
  1689. where <mode> is landscape, or portrait, <font> is stick, univers, or cg_times, 
  1690. and <fontsize> is the size in points.
  1691.  
  1692.  With pcl5 international characters are handled by the printer; you just put 
  1693. the appropriate 8-bit character codes into the text strings.  You don't need to 
  1694. bother with set encoding.
  1695.  
  1696.  HPGL graphics can be imported by many software packages.  Go Up 
  1697.  
  1698.  
  1699. ΓòÉΓòÉΓòÉ 3.31. hpljii ΓòÉΓòÉΓòÉ
  1700.  
  1701. The hpljii terminal driver supports the HP Laserjet Series II printer.  The 
  1702. hpdj driver supports the HP DeskJet 500 printer.  These drivers allow a choice 
  1703. of resolutions.
  1704.  
  1705.  Syntax: 
  1706.  
  1707.       set terminal hpljii | hpdj {<res>}
  1708.  
  1709. where res may be 75, 100, 150 or 300 dots per inch; the default is 75. 
  1710. Rasterization at the higher resolutions may require a large amount of memory.
  1711.  
  1712.  The hp500c terminal is similar to hpdj; hp500c additionally supports color and 
  1713. compression.  Go Up 
  1714.  
  1715.  
  1716. ΓòÉΓòÉΓòÉ 3.32. hppj ΓòÉΓòÉΓòÉ
  1717.  
  1718. The hppj terminal driver supports the HP PaintJet and HP3630 printers.  The 
  1719. only option is the choice of font.
  1720.  
  1721.  Syntax: 
  1722.  
  1723.       set terminal hppj {FNT5X9 | FNT9X17 | FNT13X25}
  1724.  
  1725. with the middle-sized font (FNT9X17) being the default.  Go Up 
  1726.  
  1727.  
  1728. ΓòÉΓòÉΓòÉ 3.33. imagen ΓòÉΓòÉΓòÉ
  1729.  
  1730. The imagen terminal driver supports Imagen laser printers.  It is capable of 
  1731. placing multiple graphs on a single page.
  1732.  
  1733.  Syntax: 
  1734.  
  1735.       set terminal imagen {<fontsize>} {portrait | landscape}
  1736.                           {[<horiz>,<vert>]}
  1737.  
  1738. where fontsize defaults to 12 points and the layout defaults to landscape. 
  1739. <horiz> and <vert> are the number of graphs in the horizontal and vertical 
  1740. directions; these default to unity.
  1741.  
  1742.  Example: 
  1743.  
  1744.       set terminal imagen portrait [2,3]
  1745.  
  1746. puts six graphs on the page in three rows of two in portrait orientation.  Go 
  1747. Up 
  1748.  
  1749.  
  1750. ΓòÉΓòÉΓòÉ 3.34. iris4d ΓòÉΓòÉΓòÉ
  1751.  
  1752. The iris4d terminal driver supports Silicon Graphics IRIS 4D computers. Its 
  1753. only option is 8- or 24-bit color depth.  The default is 8.
  1754.  
  1755.  Syntax: 
  1756.  
  1757.       set terminal iris4d {8 | 24}
  1758.  
  1759. The color depth is not really a choice -- the value appropriate for the 
  1760. hardware should be selected.
  1761.  
  1762.  When using 24-bit mode, the colors can be directly specified via the file 
  1763. .gnuplot_iris4d that is searched in the current directory and then in the home 
  1764. directory specified by the HOME environment variable.  This file holds RGB 
  1765. values for the background, border, labels and nine plotting colors, in that 
  1766. order.  For example, here is a file containing the default colors: 
  1767.  
  1768.       85   85   85     Background   (dark gray)
  1769.       0    0    0      Boundary     (black)
  1770.       170  0    170    Labeling     (magenta)
  1771.       85   255  255    Plot Color 1 (light cyan)
  1772.       170  0    0      Plot Color 2 (red)
  1773.       0    170  0      Plot Color 3 (green)
  1774.       255  85   255    Plot Color 4 (light magenta)
  1775.       255  255  85     Plot Color 5 (yellow)
  1776.       255  85   85     Plot Color 6 (light red)
  1777.       85   255  85     Plot Color 7 (light green)
  1778.       0    170  170    Plot Color 8 (cyan)
  1779.       170  170  0      Plot Color 9 (brown)
  1780.  
  1781. This file must have exactly 12 lines of RGB triples.  No empty lines are 
  1782. allowed, and anything after the third number on a line is ignored.  Go Up 
  1783.  
  1784.  
  1785. ΓòÉΓòÉΓòÉ 3.35. kyo ΓòÉΓòÉΓòÉ
  1786.  
  1787. The kyo and prescribe terminal drivers support the Kyocera laser printer. The 
  1788. only difference between the two is that kyo uses "Helvetica" whereas prescribe 
  1789. uses "Courier".  There are no options.  Go Up 
  1790.  
  1791.  
  1792. ΓòÉΓòÉΓòÉ 3.36. latex ΓòÉΓòÉΓòÉ
  1793.  
  1794. The latex and emtex drivers allow two options.
  1795.  
  1796.  Syntax: 
  1797.  
  1798.       set terminal latex | emtex {courier | roman} {<fontsize>}
  1799.  
  1800. fontsize may be any size you specify.  The default is 10-point Roman.
  1801.  
  1802.  Unless your driver is capable of building fonts at any size (e.g. dvips), 
  1803. stick to the standard 10, 11 and 12 point sizes.
  1804.  
  1805.  METAFONT users beware: METAFONT does not like odd sizes.
  1806.  
  1807.  All drivers for LaTeX offer a special way of controlling text positioning: If 
  1808. any text string begins with '{', you also need to include a '}' at the end of 
  1809. the text, and the whole text will be centered both horizontally and vertically 
  1810. by LaTeX. --- If the text string begins with '[', you need to continue it with: 
  1811. a position specification (up to two out of t,b,l,r), ']{', the text itself, and 
  1812. finally, '}'. The text itself may be anything LaTeX can typeset as an LR-box. 
  1813. \rule{}{}'s may help for best positioning.
  1814.  
  1815.  Examples: About label positioning: Use gnuplot defaults (mostly sensible, but 
  1816. sometimes not really best): 
  1817.  
  1818.        set title '\LaTeX\ -- $ \gamma $'
  1819.  
  1820. Force centering both horizontally and vertically: 
  1821.  
  1822.        set label '{\LaTeX\ -- $ \gamma $}' at 0,0
  1823.  
  1824. Specify own positioning (top here): 
  1825.  
  1826.        set xlabel '[t]{\LaTeX\ -- $ \gamma $}'
  1827.  
  1828. The other label -- account for long ticlabels: 
  1829.  
  1830.        set ylabel '[r]{\LaTeX\ -- $ \gamma $\rule{7mm}{0pt}'
  1831.  Go Up 
  1832.  
  1833.  
  1834. ΓòÉΓòÉΓòÉ 3.37. linux ΓòÉΓòÉΓòÉ
  1835.  
  1836. The linux driver has no additional options to specify.  It looks at the 
  1837. environment variable GSVGAMODE for the default mode; if not set, it uses 
  1838. 1024x768x256 as default mode or, if that is not possible, 640x480x16 (standard 
  1839. VGA).  Go Up 
  1840.  
  1841.  
  1842. ΓòÉΓòÉΓòÉ 3.38. macintosh ΓòÉΓòÉΓòÉ
  1843.  
  1844. Several options may be set in the 'macintosh' driver.
  1845.  
  1846.  Syntax: 
  1847.  
  1848.      set terminal macintosh {singlewin | multiwin} {vertical | novertical} {size <width>, <height> | default}
  1849.  
  1850. 'singlewin' limits the output to a single window and is useful for animations. 
  1851. 'multiwin' allows multiple windows. 'vertical' is only valid under the gx 
  1852. option. With this option, rotated text 
  1853.  
  1854.     be drawn vertically. novertical turns this option off.
  1855.  size <width>, <height> overrides the graph size set in the preferences
  1856.     dialog until it is cleared with either 'set term mac size default'
  1857.     or 'set term mac default'.
  1858.  
  1859.  'set term mac size default' sets the window size settings to those set in
  1860.     the preferences dialog.
  1861.  
  1862.  'set term mac default' sets all options to their default values.
  1863.     Default values: nogx, multiwin, novertical.
  1864.  
  1865.  If you generate graphs under the multiwin option and then switch to singlewin,
  1866.  the next plot command will cause one more window to be created. This new
  1867.  window will be reused as long as singlewin is in effect. If you switch back
  1868.  to multiwin, generate some graphs, and then switch to singlewin again, the
  1869.  orginal 'singlewin' window will be resused if it is still open. Otherwise
  1870.  a new 'singlewin' window will be created. The 'singlewin' window is not numbered.
  1871.  Go Up 
  1872.  
  1873.  
  1874. ΓòÉΓòÉΓòÉ 3.39. mf ΓòÉΓòÉΓòÉ
  1875.  
  1876. The mf terminal driver creates a input file to the METAFONT program.  Thus a 
  1877. figure may be used in the TeX document in the same way as is a character.
  1878.  
  1879.  To use a picture in a document, the METAFONT program must be run with the 
  1880. output file from gnuplot as input.  Thus, the user needs a basic knowledge of 
  1881. the font creating process and the procedure for including a new font in a 
  1882. document.  However, if the METAFONT program is set up properly at the local 
  1883. site, an unexperienced user could perform the operation without much trouble.
  1884.  
  1885.  The text support is based on a METAFONT character set.  Currently the Computer 
  1886. Modern Roman font set is input, but the user is in principal free to chose 
  1887. whatever fonts he or she needs.  The METAFONT source files for the chosen font 
  1888. must be available.  Each character is stored in a separate picture variable in 
  1889. METAFONT.  These variables may be manipulated (rotated, scaled etc.) when 
  1890. characters are needed.  The drawback is the interpretation time in the METAFONT 
  1891. program.  On some machines (i.e. PC) the limited amount of memory available may 
  1892. also cause problems if too many pictures are stored.
  1893.  
  1894.  The mf terminal has no options.  Go Up 
  1895.  
  1896.  
  1897. ΓòÉΓòÉΓòÉ 3.39.1. METAFONT Instructions ΓòÉΓòÉΓòÉ
  1898.  
  1899. - Set your terminal to METAFONT: 
  1900.  
  1901.   set terminal mf
  1902.  
  1903. - Select an output-file, e.g.: 
  1904.  
  1905.   set output "myfigures.mf"
  1906.  
  1907. - Create your pictures. Each picture will generate a separate character. Its 
  1908. default size will be 5*3 inches. You can change the size by saying set size 
  1909. 0.5,0.5 or whatever fraction of the default size you want to have.
  1910.  
  1911.  - Quit gnuplot.
  1912.  
  1913.  - Generate a TFM and GF file by running METAFONT on the output of gnuplot. 
  1914. Since the picture is quite large (5*3 in), you will have to use a version of 
  1915. METAFONT that has a value of at least 150000 for memmax.  On Unix systems these 
  1916. are conventionally installed under the name bigmf.  For the following assume 
  1917. that the command virmf stands for a big version of METAFONT.  For example:
  1918.  
  1919.  - Invoke METAFONT: 
  1920.  
  1921.     virmf '&plain'
  1922.  
  1923. - Select the output device: At the METAFONT prompt ('*') type: 
  1924.  
  1925.     \mode:=CanonCX;     % or whatever printer you use
  1926.  
  1927. - Optionally select a magnification: 
  1928.  
  1929.     mag:=1;             % or whatever you wish
  1930.  
  1931. - Input the gnuplot-file: 
  1932.  
  1933.     input myfigures.mf
  1934.  
  1935. On a typical Unix machine there will usually be a script called "mf" that 
  1936. executes virmf '&plain', so you probably can substitute mf for virmf &plain. 
  1937. This will generate two files: mfput.tfm and mfput.$$$gf (where $$$ indicates 
  1938. the resolution of your device).  The above can be conveniently achieved by 
  1939. typing everything on the command line, e.g.: virmf '&plain' '\mode:=CanonCX; 
  1940. mag:=1; input myfigures.mf' In this case the output files will be named 
  1941. myfigures.tfm and myfigures.300gf.
  1942.  
  1943.  - Generate a PK file from the GF file using gftopk: 
  1944.  
  1945.   gftopk myfigures.300gf myfigures.300pk
  1946.  
  1947. The name of the output file for gftopk depends on the DVI driver you use. Ask 
  1948. your local TeX administrator about the naming conventions.  Next, either 
  1949. install the TFM and PK files in the appropriate directories, or set your 
  1950. environment variables properly.  Usually this involves setting TEXFONTS to 
  1951. include the current directory and doing the same thing for the environment 
  1952. variable that your DVI driver uses (no standard name here...).  This step is 
  1953. necessary so that TeX will find the font metric file and your DVI driver will 
  1954. find the PK file.
  1955.  
  1956.  - To include your pictures in your document you have to tell TeX the font: 
  1957.  
  1958.   \font\gnufigs=myfigures
  1959.  
  1960. Each picture you made is stored in a single character.  The first picture is 
  1961. character 0, the second is character 1, and so on...  After doing the above 
  1962. step, you can use the pictures just like any other characters.  Therefore, to 
  1963. place pictures 1 and 2 centered in your document, all you have to do is: 
  1964.  
  1965.   \centerline{\gnufigs\char0}
  1966.   \centerline{\gnufigs\char1}
  1967.  
  1968. in plain TeX.  For LaTeX you can, of course, use the picture environment and 
  1969. place the picture wherever you wish by using the \makebox and \put macros.
  1970.  
  1971.  This conversion saves you a lot of time once you have generated the font; TeX 
  1972. handles the pictures as characters and uses minimal time to place them, and the 
  1973. documents you make change more often than the pictures do.  It also saves a lot 
  1974. of TeX memory.  One last advantage of using the METAFONT driver is that the DVI 
  1975. file really remains device independent, because no \special commands are used 
  1976. as in the eepic and tpic drivers.  Go Up 
  1977.  
  1978.  
  1979. ΓòÉΓòÉΓòÉ 3.40. mgr ΓòÉΓòÉΓòÉ
  1980.  
  1981. The mgr terminal driver supports the Mgr Window system.  It has no options.  Go 
  1982. Up 
  1983.  
  1984.  
  1985. ΓòÉΓòÉΓòÉ 3.41. mif ΓòÉΓòÉΓòÉ
  1986.  
  1987. The mif terminal driver produces Frame Maker MIF format version 3.00.  It plots 
  1988. in MIF Frames with the size 15*10 cm, and plot primitives with the same pen 
  1989. will be grouped in the same MIF group.  Plot primitives in a gnuplot page will 
  1990. be plotted in a MIF Frame, and several MIF Frames are collected in one large 
  1991. MIF Frame.  The MIF font used for text is "Times".
  1992.  
  1993.  Several options may be set in the MIF 3.00 driver.
  1994.  
  1995.  Syntax: 
  1996.  
  1997.       set terminal mif {colour | monochrome} {polyline | vectors}
  1998.                        {help | ?}
  1999.  
  2000. colour plots lines with line types >= 0 in colour (MIF sep. 2--7) and 
  2001. monochrome plots all line types in black (MIF sep. 0). polyline plots curves as 
  2002. continuous curves and vectors plots curves as collections of vectors. help and 
  2003. ? print online help on standard error output---both print a short description 
  2004. of the usage; help also lists the options;
  2005.  
  2006.  Examples: 
  2007.  
  2008.       set term mif colour polylines    # defaults
  2009.       set term mif                     # defaults
  2010.       set term mif vectors
  2011.       set term mif help
  2012.  Go Up 
  2013.  
  2014.  
  2015. ΓòÉΓòÉΓòÉ 3.42. mtos ΓòÉΓòÉΓòÉ
  2016.  
  2017. The mtos terminal has no options.  It sends data via a pipe to an external 
  2018. program called GPCLIENT.  It runs under MULTITOS, Magic 3.x, MagicMAC. and 
  2019. MiNT.  If you cannot find GPCLIENT, than mail to dirk@lstm.uni-erlangen.de.  Go 
  2020. Up 
  2021.  
  2022.  
  2023. ΓòÉΓòÉΓòÉ 3.43. next ΓòÉΓòÉΓòÉ
  2024.  
  2025. Several options may be set in the next driver.
  2026.  
  2027.  Syntax: 
  2028.  
  2029.       set terminal next {<mode>} {<type> } {<color>} {<dashed>}
  2030.                  {"<fontname>"} {<fontsize>} title {"<newtitle>"}
  2031.  
  2032. where <mode> is  default, which sets all options to their defaults; <type> is 
  2033. either new or old, where old invokes the old single window; <color> is either 
  2034. color or monochrome; <dashed> is either solid or dashed; "<fontname>" is the 
  2035. name of a valid PostScript font; <fontsize> is the size of the font in 
  2036. PostScript points; and <title> is the title for the GnuTerm window. Defaults 
  2037. are  new, monochrome, dashed, "Helvetica", 14pt.
  2038.  
  2039.  Examples: 
  2040.  
  2041.       set term next default
  2042.       set term next 22
  2043.       set term next color "Times-Roman" 14
  2044.       set term next color "Helvetica" 12 title "MyPlot"
  2045.       set term next old
  2046.  
  2047. Pointsizes may be changed with set linestyle.  Go Up 
  2048.  
  2049.  
  2050. ΓòÉΓòÉΓòÉ 3.44. pbm ΓòÉΓòÉΓòÉ
  2051.  
  2052. Several options may be set in the pbm terminal---the driver for PBMplus.
  2053.  
  2054.  Syntax: 
  2055.  
  2056.       set terminal pbm {<fontsize>} {<mode>}
  2057.  
  2058. where <fontsize> is small, medium, or large and <mode> is monochrome, gray or 
  2059. color.  The default plot size is 640 pixels wide and 480 pixels high; this may 
  2060. be changed by set size.
  2061.  
  2062.  The output of the pbm driver depends upon <mode>: monochrome produces a 
  2063. portable bitmap (one bit per pixel), gray a portable graymap (three bits per 
  2064. pixel) and color a portable pixmap (color, four bits per pixel).
  2065.  
  2066.  The output of this driver can be used with Jef Poskanzer's excellent PBMPLUS 
  2067. package, which provides programs to convert the above PBMPLUS formats to GIF, 
  2068. TIFF, MacPaint, Macintosh PICT, PCX, X11 bitmap and many others.  PBMPLUS may 
  2069. be obtained from ftp.x.org.  The relevant files have names that begin with 
  2070. "netpbm-1mar1994.p1"; they reside in /contrib/utilities.  The package can 
  2071. probably also be obtained from one of the many sites that mirrors ftp.x.org.
  2072.  
  2073.  Examples: 
  2074.  
  2075.       set terminal pbm small monochrome             # defaults
  2076.       set size 2,2; set terminal pbm color medium
  2077.  Go Up 
  2078.  
  2079.  
  2080. ΓòÉΓòÉΓòÉ 3.45. dospc ΓòÉΓòÉΓòÉ
  2081.  
  2082. The dospc terminal driver supports PCs with arbitrary graphics boards, which 
  2083. will be automatically detected.  It should be used only if you are not using 
  2084. the gcc or Zortec C/C++ compilers.  Go Up 
  2085.  
  2086.  
  2087. ΓòÉΓòÉΓòÉ 3.46. pm ΓòÉΓòÉΓòÉ
  2088.  
  2089. The pm terminal driver provides an OS/2 Presentation Manager window in which 
  2090. the graph is plotted.  The window is opened when the first graph is plotted. 
  2091. This window has its own online help as well as facilities for printing, copying 
  2092. to the clipboard and some line type and color adjustments. The multiplot option 
  2093. is supported.
  2094.  
  2095.  Syntax: 
  2096.  
  2097.       set terminal pm {server {n}} {persist} {widelines} {enhanced} {"title"}
  2098.  
  2099. If persist is specified, each graph appears in its own window and all windows 
  2100. remain open after gnuplot exits.  If server is specified, all graphs appear in 
  2101. the same window, which remains open when gnuplot exits. This option takes an 
  2102. optional numerical argument which specifies an instance of the server process. 
  2103. Thus multiple server windows can be in use at the same time.
  2104.  
  2105.  If widelines is specified, all plots will be drawn with wide lines.  If 
  2106. enhanced is specified, sub- and superscripts and multiple fonts are enabled 
  2107. using the same syntax as the enhanced postscript option (see set terminal 
  2108. postscript enhanced for details).  Font names for the basic PostScript fonts 
  2109. may be abbreviated to single letters.
  2110.  
  2111.  If title is specified, it will be used as the title of the plot window. It 
  2112. will also be used as the name of the server instance, and will override the 
  2113. optional numerical argument.
  2114.  
  2115.  Linewidths may be changed with set linestyle.  Go Up 
  2116.  
  2117.  
  2118. ΓòÉΓòÉΓòÉ 3.47. png ΓòÉΓòÉΓòÉ
  2119.  
  2120. The png terminal driver supports Portable Network Graphics.  To compile it, you 
  2121. will need  the third-party libraries "libpng" and "zlib"; both are available at 
  2122. ftp://ftp.uu.net/graphics/png.  png has two options.
  2123.  
  2124.  Syntax: 
  2125.  
  2126.       set terminal png {small | medium | large}
  2127.                        {monochrome | gray | color}
  2128.  
  2129. The defaults are small (fontsize) and monochrome.  Go Up 
  2130.  
  2131.  
  2132. ΓòÉΓòÉΓòÉ 3.48. postscript ΓòÉΓòÉΓòÉ
  2133.  
  2134. Several options may be set in the postscript driver.
  2135.  
  2136.  Syntax: 
  2137.  
  2138.       set terminal postscript {<mode>} {enhanced | noenhanced}
  2139.                               {color | monochrome} {solid | dashed}
  2140.                               {<duplexing>}
  2141.                               {"<fontname>"} {<fontsize>}
  2142.  
  2143. where <mode> is landscape, portrait, eps or default; solid draws all plots with 
  2144. solid lines, overriding any dashed patterns; <duplexing> is defaultplex, 
  2145. simplex or duplex ("duplexing" in PostScript is the ability of the printer to 
  2146. print on both sides of the same page---don't set this if your printer can't do 
  2147. it); enhanced activates the "enhanced PostScript" features (subscripts, 
  2148. superscripts and mixed fonts); "<fontname"> is the name of a valid PostScript 
  2149. font; and <fontsize> is the size of the font in PostScript points.
  2150.  
  2151.  default mode sets all options to their defaults: landscape, monochrome, 
  2152. dashed, defaultplex, noenhanced, "Helvetica" and 14pt. 
  2153.  
  2154.  Default size of a PostScript plot is 10 inches wide and 7 inches high.
  2155.  
  2156. eps mode generates EPS (Encapsulated PostScript) output, which is just regular 
  2157. PostScript with some additional lines that allow the file to be imported into a 
  2158. variety of other applications.  (The added lines are PostScript comment lines, 
  2159. so the file may still be printed by itself.)  To get EPS output, use the eps 
  2160. mode and make only one plot per file.  In eps mode the whole plot, including 
  2161. the fonts, is reduced to half of the default size.
  2162.  
  2163.  Examples: 
  2164.  
  2165.       set terminal postscript default       # old postscript
  2166.       set terminal postscript enhanced      # old enhpost
  2167.       set terminal postscript landscape 22  # old psbig
  2168.       set terminal postscript eps 14        # old epsf1
  2169.       set terminal postscript eps 22        # old epsf2
  2170.       set size 0.7,1.4; set term post portrait color "Times-Roman" 14
  2171.  
  2172. Linewidths and pointsizes may be changed with set linestyle.
  2173.  
  2174.  The postscript driver supports about 70 distinct pointtypes, selectable 
  2175. through the pointtype option on plot and set linestyle.
  2176.  
  2177.  Several possibly useful files about gnuplot's PostScript are included in the 
  2178. /docs/ps subdirectory of the gnuplot distribution and at the distribution 
  2179. sites.  These are "ps_symbols.gpi" (a gnuplot command file that, when executed, 
  2180. creates the file "ps_symbols.ps" which shows all the symbols available through 
  2181. the postscript terminal), "ps_guide.ps" (a PostScript file that contains a 
  2182. summary of the enhanced syntax and a page showing what the octal codes produce 
  2183. with text and symbol fonts) and "ps_file.doc" (a text file that contains a 
  2184. discussion of the organization of a PostScript file written by gnuplot).
  2185.  
  2186.  A PostScript file is editable, so once gnuplot has created one, you are free 
  2187. to modify it to your heart's desire.  See the "editing postscript" section for 
  2188. some hints.  Go Up 
  2189.  
  2190.  
  2191. ΓòÉΓòÉΓòÉ 3.48.1. enhanced postscript ΓòÉΓòÉΓòÉ
  2192.  
  2193.   Control      Examples        Explanation
  2194.    ^           a^x             superscript
  2195.    _           a_x             subscript
  2196.    @           @x or a@^b_c    phantom box (occupies no width)
  2197.    &           &{space}        inserts space of specified length
  2198.  
  2199. Braces can be used to place multiple-character text where a single character is 
  2200. expected (e.g., 2^{10}).  To change the font and/or size, use the full form: 
  2201. {/[fontname][=fontsize | *fontscale] text}.  Thus {/Symbol=20 G} is a 20-point 
  2202. GAMMA) and {/*0.75 K} is a K at three-quarters of whatever fontsize is 
  2203. currently in effect.  (The '/' character MUST be the first character after the '{'.)
  2204.  
  2205.  If the encoding vector has been changed by set encoding, the default encoding 
  2206. vector can be used instead by following the slash with a dash.  This is 
  2207. unnecessary if you use the Symbol font, however---since /Symbol uses its own 
  2208. encoding vector, gnuplot will not apply any other encoding vector to it.
  2209.  
  2210.  The phantom box is useful for a@^b_c to align superscripts and subscripts but 
  2211. does not work well for overwriting an accent on a letter.  (To do the latter, 
  2212. it is much better to use set encoding iso_8859_1 to change to the ISO Latin-1 
  2213. encoding vector, which contains a large variety of letters with accents or 
  2214. other diacritical marks.)  Since the box is non-spacing, it is sensible to put 
  2215. the shorter of the subscript or superscript in the box (that is, after the @).
  2216.  
  2217.  Space equal in length to a string can be inserted using the '&' character. 
  2218. Thus 
  2219.  
  2220.         'abc&{def}ghi'
  2221.  
  2222. would produce 
  2223.  
  2224.         'abc   ghi'.
  2225.  
  2226. You can access special symbols numerically by specifying \character-code (in 
  2227. octal), e.g., {/Symbol \245} is the symbol for infinity.
  2228.  
  2229.  You can escape control characters using \, e.g.,  \\, \{, and so on.
  2230.  
  2231.  But be aware that strings in double-quotes are parsed differently than those 
  2232. enclosed in single-quotes.  The major difference is that backslashes may need 
  2233. to be doubled when in double-quoted strings.
  2234.  
  2235.  Examples (these are hard to describe in words---try them!): 
  2236.  
  2237.       set xlabel 'Time (10^6 {/Symbol m}s)'
  2238.       set title '{/Symbol=18 \362@_{/=9.6 0}^{/=12 x}} \
  2239.                  {/Helvetica e^{-{/Symbol m}^2/2} d}{/Symbol m}'
  2240.  
  2241. The file "ps_guide.ps" in the /docs/ps subdirectory of the gnuplot source 
  2242. distribution contains more examples of the enhanced syntax.  Go Up 
  2243.  
  2244.  
  2245. ΓòÉΓòÉΓòÉ 3.48.2. editing postscript ΓòÉΓòÉΓòÉ
  2246.  
  2247. The PostScript language is a very complex language---far too complex to 
  2248. describe in any detail in this document.  Nevertheless there are some things in 
  2249. a PostScript file written by gnuplot that can be changed without risk of 
  2250. introducing fatal errors into the file.
  2251.  
  2252.  For example, the PostScript statement "/Color true def" (written into the file 
  2253. in response to the command set terminal postscript color), may be altered in an 
  2254. obvious way to generate a black-and-white version of a plot. Similarly line 
  2255. colors, text colors, line weights and symbol sizes can also be altered in 
  2256. straight-forward ways.  Text (titles and labels) can be edited to correct 
  2257. misspellings or to change fonts.  Anything can be repositioned, and of course 
  2258. anything can be added or deleted, but modifications such as these may require 
  2259. deeper knowledge of the PostScript language.
  2260.  
  2261.  The organization of a PostScript file written by gnuplot is discussed in the 
  2262. text file "ps_file.doc" in the /docs/ps subdirectory.  Go Up 
  2263.  
  2264.  
  2265. ΓòÉΓòÉΓòÉ 3.49. pslatex and pstex ΓòÉΓòÉΓòÉ
  2266.  
  2267. The pslatex and pstex drivers generate output for further processing by LaTeX 
  2268. and TeX, respectively.  Figures generated by pstex can be included in any 
  2269. plain-based format (including LaTeX).
  2270.  
  2271.  Syntax: 
  2272.  
  2273.       set terminal pslatex | |pstex {<color>} {<dashed>} {<rotate>}
  2274.                                     {auxfile} {<font_size>}
  2275.  
  2276. <color> is either color or monochrome.  <rotate> is either rotate or norotate 
  2277. and determines if the y-axis label is rotated.  <font_size> is used to scale 
  2278. the font from its usual size.
  2279.  
  2280.  If auxfile is specified, it directs the driver to put the PostScript commands 
  2281. into an auxiliary file instead of directly into the LaTeX file. This is useful 
  2282. if your pictures are large enough that dvips cannot handle them.  The name of 
  2283. the auxiliary PostScript file is derived from the name of the TeX file given on 
  2284. the set output command; it is determined by replacing the trailing .tex 
  2285. (actually just the final extent in the file name---and the option will be 
  2286. turned off if there is no extent) with .ps in the output file name.  Remember 
  2287. to close the file before leaving gnuplot.
  2288.  
  2289.  All drivers for LaTeX offer a special way of controlling text positioning: If 
  2290. any text string begins with '{', you also need to include a '}' at the end of 
  2291. the text, and the whole text will be centered both horizontally and vertically 
  2292. by LaTeX. --- If the text string begins with '[', you need to continue it with: 
  2293. a position specification (up to two out of t,b,l,r), ']{', the text itself, and 
  2294. finally, '}'. The text itself may be anything LaTeX can typeset as an LR-box. 
  2295. \rule{}{}'s may help for best positioning.
  2296.  
  2297.  Examples: 
  2298.  
  2299.       set term pslatex monochrome dashed rotate       # set to defaults
  2300.  
  2301. To write the PostScript commands into the file "foo.ps": 
  2302.  
  2303.       set term pslatex auxfile
  2304.       set output "foo.tex"; plot ...: set output
  2305.  
  2306. About label positioning: Use gnuplot defaults (mostly sensible, but sometimes 
  2307. not really best): 
  2308.  
  2309.        set title '\LaTeX\ -- $ \gamma $'
  2310.  
  2311. Force centering both horizontally and vertically: 
  2312.  
  2313.        set label '{\LaTeX\ -- $ \gamma $}' at 0,0
  2314.  
  2315. Specify own positioning (top here): 
  2316.  
  2317.        set xlabel '[t]{\LaTeX\ -- $ \gamma $}'
  2318.  
  2319. The other label -- account for long ticlabels: 
  2320.  
  2321.        set ylabel '[r]{\LaTeX\ -- $ \gamma $\rule{7mm}{0pt}'
  2322.  
  2323. Linewidths and pointsizes may be changed with set linestyle.  Go Up 
  2324.  
  2325.  
  2326. ΓòÉΓòÉΓòÉ 3.50. pstricks ΓòÉΓòÉΓòÉ
  2327.  
  2328. The pstricks driver is intended for use with the "pstricks.sty" macro package 
  2329. for LaTeX.  It is an alternative to the eepic and latex drivers. You need 
  2330. "pstricks.sty", and, of course, a printer that understands PostScript, or a 
  2331. converter such as Ghostscript.
  2332.  
  2333.  PSTricks is available via anonymous ftp from the /pub directory at 
  2334. Princeton.EDU.  This driver definitely does not come close to using the full 
  2335. capability of the PSTricks package.
  2336.  
  2337.  Syntax: 
  2338.  
  2339.       set terminal pstricks {hacktext | nohacktext} {unit | nounit}
  2340.  
  2341. The first option invokes an ugly hack that gives nicer numbers; the second has 
  2342. to do with plot scaling.  The defaults are hacktext and nounit.  Go Up 
  2343.  
  2344.  
  2345. ΓòÉΓòÉΓòÉ 3.51. qms ΓòÉΓòÉΓòÉ
  2346.  
  2347. The qms terminal driver supports the QMS/QUIC Laser printer, the Talaris 1200 
  2348. and others.  It has no options.  Go Up 
  2349.  
  2350.  
  2351. ΓòÉΓòÉΓòÉ 3.52. regis ΓòÉΓòÉΓòÉ
  2352.  
  2353. The regis terminal device generates output in the REGIS graphics language. It 
  2354. has the option of using 4 (the default) or 16 colors.
  2355.  
  2356.  Syntax: 
  2357.  
  2358.       set terminal regis {4 | 16}
  2359.  Go Up 
  2360.  
  2361.  
  2362. ΓòÉΓòÉΓòÉ 3.53. rgip ΓòÉΓòÉΓòÉ
  2363.  
  2364. The rgip and uniplex terminal drivers support RGIP metafiles.  They can combine 
  2365. several graphs on a single page, but only one page is allowed in a given output file.
  2366.  
  2367.  Syntax: 
  2368.  
  2369.       set terminal rgip | uniplex {portrait | landscape}
  2370.                                   {[<horiz>,<vert>]} {<fontsize>}
  2371.  
  2372. permissible values for the font size are in the range 1--8, with the default 
  2373. being 1.  The default layout is landscape.  Graphs are placed on the page in a 
  2374. horizxvert grid, which defaults to [1,1].
  2375.  
  2376.  Example: 
  2377.  
  2378.       set terminal uniplex portrait [2,3]
  2379.  
  2380. puts six graphs on a page in three rows of two in portrait orientation.  Go Up 
  2381.  
  2382.  
  2383. ΓòÉΓòÉΓòÉ 3.54. sun ΓòÉΓòÉΓòÉ
  2384.  
  2385. The sun terminal driver supports the SunView window system.  It has no options. 
  2386. Go Up 
  2387.  
  2388.  
  2389. ΓòÉΓòÉΓòÉ 3.55. tek410x ΓòÉΓòÉΓòÉ
  2390.  
  2391. The tek410x terminal driver supports the 410x and 420x family of Tektronix 
  2392. terminals.  It has no options.  Go Up 
  2393.  
  2394.  
  2395. ΓòÉΓòÉΓòÉ 3.56. table ΓòÉΓòÉΓòÉ
  2396.  
  2397. Instead of producing a graph, the table terminal prints out the points on which 
  2398. a graph would be based, i.e., the results of processing the plot or splot 
  2399. command, in a multicolumn ASCII table of X Y {Z} R values.  The character R 
  2400. takes on one of three values: "i" if the point is in the active range, "o" if 
  2401. it is out-of-range, or "u" if it is undefined.  The data format is determined 
  2402. by the format of the axis labels (see set format).
  2403.  
  2404.  For those times when you want the numbers, you can display them on the screen 
  2405. or save them to a file.  This can be useful if you want to generate contours 
  2406. and then save them for further use, perhaps for plotting with plot;  see set 
  2407. contour for an example.  The same method can be used to save interpolated data 
  2408. (see set samples and set dgrid3d).  Go Up 
  2409.  
  2410.  
  2411. ΓòÉΓòÉΓòÉ 3.57. tek40 ΓòÉΓòÉΓòÉ
  2412.  
  2413. This family of terminal drivers supports a variety of VT-like terminals. 
  2414. tek40xx supports Tektronix 4010 and others as well as most TEK emulators; vttek 
  2415. supports VT-like tek40xx terminal emulators; kc-tek40xx supports MS-DOS Kermit 
  2416. Tek4010 terminal emulators in color: km-tek40xx supports them in monochrome; 
  2417. selanar supports Selanar graphics; and bitgraph supports BBN Bitgraph 
  2418. terminals.  None have any options.  Go Up 
  2419.  
  2420.  
  2421. ΓòÉΓòÉΓòÉ 3.58. texdraw ΓòÉΓòÉΓòÉ
  2422.  
  2423. The texdraw terminal driver supports the LaTeX texdraw environment.  It is 
  2424. intended for use with "texdraw.sty" and "texdraw.tex" in the texdraw package.
  2425.  
  2426.  It has no options.  Go Up 
  2427.  
  2428.  
  2429. ΓòÉΓòÉΓòÉ 3.59. tgif ΓòÉΓòÉΓòÉ
  2430.  
  2431. Tgif is an X11-based drawing tool---it has nothing to do with GIF.
  2432.  
  2433.  The tgif driver supports different pointsizes (with set pointsize), different 
  2434. label fonts and font sizes (e.g. set label "Hallo" at x,y font "Helvetica,34") 
  2435. and multiple graphs on the page.  The proportions of the axes are not changed.
  2436.  
  2437.  Syntax: 
  2438.  
  2439.       set terminal tgif {portrait | landscape} {<[x,y]>}
  2440.                         {solid | dashed}
  2441.                         {"<fontname>"} {<fontsize>}
  2442.  
  2443. where <[x,y]> specifies the number of graphs in the x and y directions on the 
  2444. page, "<fontname>" is the name of a valid PostScript font, and <fontsize> 
  2445. specifies the size of the PostScript font.  Defaults are portrait, [1,1], 
  2446. dashed, "Helvetica", and 18.
  2447.  
  2448.  The solid option is usually prefered if lines are colored, as they often are 
  2449. in the editor.  Hardcopy will be black-and-white, so dashed should be chosen 
  2450. for that.
  2451.  
  2452.  Multiplot is implemented in two different ways.
  2453.  
  2454.  The first multiplot implementation is the standard gnuplot multiplot feature: 
  2455.  
  2456.       set terminal tgif
  2457.       set output "file.obj"
  2458.       set multiplot
  2459.       set origin x01,y01
  2460.       set size  xs,ys
  2461.       plot ...
  2462.            ...
  2463.       set origin x02,y02
  2464.       plot ...
  2465.       set nomultiplot
  2466.  
  2467. See set multiplot for further information.
  2468.  
  2469.  The second version is the [x,y] option for the driver itself.  The advantage 
  2470. of this implementation is that everything is scaled and placed automatically 
  2471. without the need for setting origins and sizes; the graphs keep their natural 
  2472. x/y proportions of 3/2 (or whatever is fixed by set size).
  2473.  
  2474.  If both multiplot methods are selected, the standard method is chosen and a 
  2475. warning message is given.
  2476.  
  2477.  Examples of single plots (or standard multiplot): 
  2478.  
  2479.       set terminal tgif                  # defaults
  2480.       set terminal tgif "Times-Roman" 24
  2481.       set terminal tgif landscape
  2482.       set terminal tgif landscape solid
  2483.  
  2484. Examples using the built-in multiplot mechanism: 
  2485.  
  2486.       set terminal tgif portrait [2,4]  # portrait; 2 plots in the x-
  2487.                                         # and 4 in the y-direction
  2488.       set terminal tgif [1,2]           # portrait; 1 plot in the x-
  2489.                                         # and 2 in the y-direction
  2490.       set terminal tgif landscape [3,3] # landscape; 3 plots in both
  2491.                                         # directions
  2492.  Go Up 
  2493.  
  2494.  
  2495. ΓòÉΓòÉΓòÉ 3.60. tkcanvas ΓòÉΓòÉΓòÉ
  2496.  
  2497. This terminal driver generates tk canvas widget commands.  To use it, rebuild 
  2498. gnuplot (after uncommenting or inserting the appropriate line in "term.h"), 
  2499. then 
  2500.  
  2501.  gnuplot> set term tkcanvas
  2502.  gnuplot> set output 'plot.file'
  2503.  
  2504. After invoking "wish", execute the following sequence of tcl commands: 
  2505.  
  2506.  % source plot.file
  2507.  % canvas .c
  2508.  % pack .c
  2509.  % gnuplot .c
  2510.  
  2511. The code generated by gnuplot creates a tcl procedure called "gnuplot" that 
  2512. takes the name of a canvas as its argument.  When the procedure is, called, it 
  2513. clears the canvas, finds the size of the canvas and draws the plot in it, 
  2514. scaled to fit.
  2515.  
  2516.  The current version of tkcanvas supports neither multiplot nor replot.  Go Up 
  2517.  
  2518.  
  2519. ΓòÉΓòÉΓòÉ 3.61. tpic ΓòÉΓòÉΓòÉ
  2520.  
  2521. The tpic terminal driver supports the LaTeX picture environment with tpic 
  2522. \specials.  It is an alternative to the latex and eepic terminal drivers. 
  2523. Options are the point size, line width, and dot-dash interval.
  2524.  
  2525.  Syntax: 
  2526.  
  2527.       set terminal tpic <pointsize> <linewidth> <interval>
  2528.  
  2529. where pointsize and linewidth are integers in milli-inches and interval is a 
  2530. float in inches.  If a non-positive value is specified, the default is chosen: 
  2531. pointsize = 40, linewidth = 6, interval = 0.1.
  2532.  
  2533.  All drivers for LaTeX offer a special way of controlling text positioning: If 
  2534. any text string begins with '{', you also need to include a '}' at the end of 
  2535. the text, and the whole text will be centered both horizontally and vertically 
  2536. by LaTeX. --- If the text string begins with '[', you need to continue it with: 
  2537. a position specification (up to two out of t,b,l,r), ']{', the text itself, and 
  2538. finally, '}'. The text itself may be anything LaTeX can typeset as an LR-box. 
  2539. \rule{}{}'s may help for best positioning.
  2540.  
  2541.  Examples: About label positioning: Use gnuplot defaults (mostly sensible, but 
  2542. sometimes not really best): 
  2543.  
  2544.        set title '\LaTeX\ -- $ \gamma $'
  2545.  
  2546. Force centering both horizontally and vertically: 
  2547.  
  2548.        set label '{\LaTeX\ -- $ \gamma $}' at 0,0
  2549.  
  2550. Specify own positioning (top here): 
  2551.  
  2552.        set xlabel '[t]{\LaTeX\ -- $ \gamma $}'
  2553.  
  2554. The other label -- account for long ticlabels: 
  2555.  
  2556.        set ylabel '[r]{\LaTeX\ -- $ \gamma $\rule{7mm}{0pt}'
  2557.  Go Up 
  2558.  
  2559.  
  2560. ΓòÉΓòÉΓòÉ 3.62. unixpc ΓòÉΓòÉΓòÉ
  2561.  
  2562. The unixpc terminal driver supports AT&T 3b1 and AT&T 7300 Unix PC.  It has no 
  2563. options.  Go Up 
  2564.  
  2565.  
  2566. ΓòÉΓòÉΓòÉ 3.63. unixplot ΓòÉΓòÉΓòÉ
  2567.  
  2568. The unixplot terminal driver generates output in the Unix "plot" graphics 
  2569. language.  It has no options.
  2570.  
  2571.  This terminal cannot be compiled if the GNU version of plot is to be used; in 
  2572. that case, use the gnugraph terminal instead.  Go Up 
  2573.  
  2574.  
  2575. ΓòÉΓòÉΓòÉ 3.64. vx384 ΓòÉΓòÉΓòÉ
  2576.  
  2577. The vx384 terminal driver supports the Vectrix 384 and Tandy color printers. 
  2578. It has no options.  Go Up 
  2579.  
  2580.  
  2581. ΓòÉΓòÉΓòÉ 3.65. VWS ΓòÉΓòÉΓòÉ
  2582.  
  2583. The VWS terminal driver supports the VAX Windowing System.  It has no options. 
  2584. It will sense the display type (monochrome, gray scale, or color.)  All line 
  2585. styles are plotted as solid lines.  Go Up 
  2586.  
  2587.  
  2588. ΓòÉΓòÉΓòÉ 3.66. windows ΓòÉΓòÉΓòÉ
  2589.  
  2590. Three options may be set in the windows terminal driver.
  2591.  
  2592.  Syntax: 
  2593.  
  2594.       set terminal windows {<color>} {"<fontname>"} {<fontsize>}
  2595.  
  2596. where <color> is either color or monochrome, "<fontname"> is the name of a 
  2597. valid Windows font, and <fontsize> is the size of the font in points.
  2598.  
  2599.  Other options may be set with the graph-menu, the initialization file, and set linestyle.
  2600.  
  2601.  The Windows version normally terminates immediately as soon as the end of any 
  2602. files given as command line arguments is reached (i.e. in non-interactive 
  2603. mode). It will also not show the text-window at all, in this mode, only the 
  2604. plot. By giving the optional argument /noend or -noend, you can disable this 
  2605. behaviour.  Go Up 
  2606.  
  2607.  
  2608. ΓòÉΓòÉΓòÉ 3.66.1. graph-menu ΓòÉΓòÉΓòÉ
  2609.  
  2610. The gnuplot graph window has the following options on a pop-up menu accessed by 
  2611. pressing the right mouse button or selecting Options from the system menu:
  2612.  
  2613.  Bring to Top when checked brings the graph window to the top after every plot.
  2614.  
  2615.  Color when checked enables color linestyles.  When unchecked it forces 
  2616. monochrome linestyles.
  2617.  
  2618.  Copy to Clipboard copies a bitmap and a Metafile picture.
  2619.  
  2620.  Background... sets the window background color.
  2621.  
  2622.  Choose Font... selects the font used in the graphics window.
  2623.  
  2624.  Line Styles... allows customization of the line colors and styles.
  2625.  
  2626.  Print... prints the graphics windows using a Windows printer driver and allows 
  2627. selection of the printer and scaling of the output.  The output produced by 
  2628. Print is not as good as that from gnuplot's own printer drivers.
  2629.  
  2630.  Update wgnuplot.ini saves the current window locations, window sizes, text 
  2631. window font, text window font size, graph window font, graph window font size, 
  2632. background color and linestyles to the initialization file WGNUPLOT.INI.  Go Up 
  2633.  
  2634.  
  2635. ΓòÉΓòÉΓòÉ 3.66.2. printing ΓòÉΓòÉΓòÉ
  2636.  
  2637. In order of preference, graphs may be be printed in the following ways.
  2638.  
  2639.  1. Use the gnuplot command set terminal to select a printer and set output to 
  2640. redirect output to a file.
  2641.  
  2642.  2. Select the Print... command from the gnuplot graph window.  An extra 
  2643. command screendump does this from the text window.
  2644.  
  2645.  3. If set output "PRN" is used, output will go to a temporary file.  When you 
  2646. exit from gnuplot or when you change the output with another set output 
  2647. command, a dialog box will appear for you to select a printer port. If you 
  2648. choose OK, the output will be printed on the selected port, passing unmodified 
  2649. through the print manager.  It is possible to accidentally (or deliberately) 
  2650. send printer output meant for one printer to an incompatible printer.  Go Up 
  2651.  
  2652.  
  2653. ΓòÉΓòÉΓòÉ 3.66.3. text-menu ΓòÉΓòÉΓòÉ
  2654.  
  2655. The gnuplot text window has the following options on a pop-up menu accessed by 
  2656. pressing the right mouse button or selecting Options from the system menu:
  2657.  
  2658.  Copy to Clipboard copies marked text to the clipboard.
  2659.  
  2660.  Paste copies text from the clipboard as if typed by the user.
  2661.  
  2662.  Choose Font... selects the font used in the text window.
  2663.  
  2664.  System Colors when selected makes the text window honor the System Colors set 
  2665. using the Control Panel.  When unselected, text is black or blue on a white background.
  2666.  
  2667.  Update wgnuplot.ini saves the current text window location, text window size, 
  2668. text window font and text window font size to the initialisation file WGNUPLOT.INI.
  2669.  
  2670.  MENU BAR 
  2671.  
  2672.  If the menu file WGNUPLOT.MNU is found in the same directory as WGNUPLOT.EXE, 
  2673. then the menu specified in WGNUPLOT.MNU will be loaded. Menu commands:
  2674.  
  2675.  [Menu] starts a new menu with the name on the following line.
  2676.  
  2677.  [EndMenu] ends the current menu.
  2678.  
  2679.  [--] inserts a horizontal menu separator.
  2680.  
  2681.  [|] inserts a vertical menu separator.
  2682.  
  2683.  [Button] puts the next macro on a push button instead of a menu.
  2684.  
  2685.  Macros take two lines with the macro name (menu entry) on the first line and 
  2686. the macro on the second line.  Leading spaces are ignored.  Macro commands:
  2687.  
  2688.  [INPUT] --- Input string with prompt terminated by [EOS] or {ENTER}
  2689.  
  2690.  [EOS] --- End Of String terminator.  Generates no output.
  2691.  
  2692.  [OPEN] --- Get name of file to open from list box, with title of list box 
  2693. terminated by [EOS], followed by default filename terminated by [EOS] or 
  2694. {ENTER}.  This uses COMMDLG.DLL from Windows 3.1.
  2695.  
  2696.  [SAVE] --- Get name of file to save.  Similar to [OPEN]
  2697.  
  2698.  Macro character substitutions:
  2699.  
  2700.  {ENTER} --- Carriage Return '\r'
  2701.  
  2702.  {TAB} --- Tab '\011'
  2703.  
  2704.  {ESC} --- Escape '\033'
  2705.  
  2706.  {^A} --- '\001'
  2707.  
  2708.  ...
  2709.  
  2710.  {^_} --- '\031'
  2711.  
  2712.  Macros are limited to 256 characters after expansion.  Go Up 
  2713.  
  2714.  
  2715. ΓòÉΓòÉΓòÉ 3.66.4. wgnuplot.ini ΓòÉΓòÉΓòÉ
  2716.  
  2717. Windows gnuplot will read some of its options from the [WGNUPLOT] section of 
  2718. WGNUPLOT.INI in the Windows directory.  A sample WGNUPLOT.INI file: 
  2719.  
  2720.       [WGNUPLOT]
  2721.       TextOrigin=0 0
  2722.       TextSize=640 150
  2723.       TextFont=Terminal,9
  2724.       GraphOrigin=0 150
  2725.       GraphSize=640 330
  2726.       GraphFont=Arial,10
  2727.       GraphColor=1
  2728.       GraphToTop=1
  2729.       GraphBackground=255 255 255
  2730.       Border=0 0 0 0 0
  2731.       Axis=192 192 192 2 2
  2732.       Line1=0 0 255 0 0
  2733.       Line2=0 255 0 0 1
  2734.       Line3=255 0 0 0 2
  2735.       Line4=255 0 255 0 3
  2736.       Line5=0 0 128 0 4
  2737.  
  2738. The GraphFont entry specifies the font name and size in points.  The five 
  2739. numbers given in the Border, Axis and Line entries are the Red intensity 
  2740. (0--255), Green intensity, Blue intensity, Color Linestyle and Mono Linestyle. 
  2741. Linestyles are 0=SOLID, 1=DASH, 2=DOT, 3=DASHDOT, 4=DASHDOTDOT.  In the sample 
  2742. WGNUPLOT.INI file above, Line 2 is a green solid line in color mode, or a 
  2743. dashed line in monochrome mode.  The default line width is 1 pixel.  If 
  2744. Linestyle is negative, it specifies the width of a SOLID line in pixels.  Line1 
  2745. and any linestyle used with the points style must be SOLID with unit width.  Go 
  2746. Up 
  2747.  
  2748.  
  2749. ΓòÉΓòÉΓòÉ 3.66.5. windows3.0 ΓòÉΓòÉΓòÉ
  2750.  
  2751. Windows 3.1 is preferred, but WGNUPLOT will run under Windows 3.0 with the 
  2752. following restrictions: 1. COMMDLG.DLL and SHELL.DLL (available with Windows 
  2753. 3.1 or Borland C++ 3.1) must be in the windows directory.
  2754.  
  2755.  2. WGNUPLOT.HLP produced by Borland C++ 3.1 is in Windows 3.1 format. You need 
  2756. to use the WINHELP.EXE supplied with Borland C++ 3.1.
  2757.  
  2758.  3. It will not run in real mode due to lack of memory.
  2759.  
  2760.  4. TrueType fonts are not available in the graph window.
  2761.  
  2762.  5. Drag-drop does not work.  Go Up 
  2763.  
  2764.  
  2765. ΓòÉΓòÉΓòÉ 3.67. x11 ΓòÉΓòÉΓòÉ
  2766.  
  2767. gnuplot provides the x11 terminal type for use with X servers.  This terminal 
  2768. type is set automatically at startup if the DISPLAY environment variable is 
  2769. set, if the TERM environment variable is set to xterm, or if the -display 
  2770. command line option is used.
  2771.  
  2772.  Syntax: 
  2773.  
  2774.       set terminal x11 {reset} {<n>}
  2775.  
  2776. Multiple plot windows are supported: set terminal x11 <n> directs the output to 
  2777. plot window number n.  If n>0, the terminal number will be appended to the 
  2778. window title and the icon will be labeled gplt <n>. The active window may 
  2779. distinguished by a change in cursor (from default to crosshair.)
  2780.  
  2781.  Plot windows remain open even when the gnuplot driver is changed to a 
  2782. different device.  A plot window can be closed by pressing the letter q while 
  2783. that window has input focus, or by choosing close from a window manager menu. 
  2784. All plot windows can be closed by specifying reset, which actually terminates 
  2785. the subprocess which maintains the windows (unless -persist was specified).
  2786.  
  2787.  Plot windows will automatically be closed at the end of the session unless the 
  2788. -persist option was given.
  2789.  
  2790.  The size or aspect ratio of a plot may be changed by resizing the gnuplot window.
  2791.  
  2792.  Linewidths and pointsizes may be changed from within gnuplot with set linestyle.
  2793.  
  2794.  For terminal type x11, gnuplot accepts (when initialized) the standard X 
  2795. Toolkit options and resources such as geometry, font, and name from the command 
  2796. line arguments or a configuration file.  See the X(1) man page (or its 
  2797. equivalent) for a description of such options.
  2798.  
  2799.  A number of other gnuplot options are available for the x11 terminal. These 
  2800. may be specified either as command-line options when gnuplot is invoked or as 
  2801. resources in the configuration file "/.Xdefaults".  They are set upon 
  2802. initialization and cannot be altered during a gnuplot session.  Go Up 
  2803.  
  2804.  
  2805. ΓòÉΓòÉΓòÉ 3.67.1. command-line_options ΓòÉΓòÉΓòÉ
  2806.  
  2807. In addition to the X Toolkit options, the following options may be specified on 
  2808. the command line when starting gnuplot or as resources in your ".Xdefaults" 
  2809. file: 
  2810.  
  2811.   `-clear`   requests that the window be cleared momentarily before a
  2812.              new plot is displayed.
  2813.   `-gray`    requests grayscale rendering on grayscale or color displays.
  2814.              (Grayscale displays receive monochrome rendering by default.)
  2815.   `-mono`    forces monochrome rendering on color displays.
  2816.   `-persist` plot windows survive after main gnuplot program exits
  2817.   `-raise`   raise plot window after each plot
  2818.   `-noraise` do not raise plot window after each plot
  2819.   `-tvtwm`   requests that geometry specifications for position of the
  2820.              window be made relative to the currently displayed portion
  2821.              of the virtual root.
  2822.  
  2823. The options are shown above in their command-line syntax.  When entered as 
  2824. resources in ".Xdefaults", they require a different syntax.
  2825.  
  2826.  Example: 
  2827.  
  2828.       gnuplot*gray: on
  2829.  
  2830. gnuplot also provides a command line option (-pointsize <v>) and a resource, 
  2831. gnuplot*pointsize: <v>, to control the size of points plotted with the points 
  2832. plotting style.  The value v is a real number (greater than 0 and less than or 
  2833. equal to ten) used as a scaling factor for point sizes.  For example, 
  2834. -pointsize 2 uses points twice the default size, and -pointsize 0.5 uses points 
  2835. half the normal size.  Go Up 
  2836.  
  2837.  
  2838. ΓòÉΓòÉΓòÉ 3.67.2. monochome_options ΓòÉΓòÉΓòÉ
  2839.  
  2840. For monochrome displays, gnuplot does not honor foreground or background 
  2841. colors.  The default is black-on-white.  -rv or gnuplot*reverseVideo: on 
  2842. requests white-on-black.  Go Up 
  2843.  
  2844.  
  2845. ΓòÉΓòÉΓòÉ 3.67.3. color_resources ΓòÉΓòÉΓòÉ
  2846.  
  2847. For color displays, gnuplot honors the following resources (shown here with 
  2848. their default values) or the greyscale resources.  The values may be color 
  2849. names as listed in the X11 rgb.txt file on your system, hexadecimal RGB color 
  2850. specifications (see X11 documentation), or a color name followed by a comma and 
  2851. an intensity value from 0 to 1.  For example, blue, 0.5 means a half intensity 
  2852. blue. 
  2853.  
  2854.   gnuplot*background:  white
  2855.   gnuplot*textColor:   black
  2856.   gnuplot*borderColor: black
  2857.   gnuplot*axisColor:   black
  2858.   gnuplot*line1Color:  red
  2859.   gnuplot*line2Color:  green
  2860.   gnuplot*line3Color:  blue
  2861.   gnuplot*line4Color:  magenta
  2862.   gnuplot*line5Color:  cyan
  2863.   gnuplot*line6Color:  sienna
  2864.   gnuplot*line7Color:  orange
  2865.   gnuplot*line8Color:  coral
  2866.  
  2867. The command-line syntax for these is, for example,
  2868.  
  2869.  Example: 
  2870.  
  2871.       gnuplot -background coral
  2872.  Go Up 
  2873.  
  2874.  
  2875. ΓòÉΓòÉΓòÉ 3.67.4. grayscale_resources ΓòÉΓòÉΓòÉ
  2876.  
  2877. When -gray is selected, gnuplot honors the following resources for grayscale or 
  2878. color displays (shown here with their default values).  Note that the default 
  2879. background is black. 
  2880.  
  2881.   gnuplot*background: black
  2882.   gnuplot*textGray:   white
  2883.   gnuplot*borderGray: gray50
  2884.   gnuplot*axisGray:   gray50
  2885.   gnuplot*line1Gray:  gray100
  2886.   gnuplot*line2Gray:  gray60
  2887.   gnuplot*line3Gray:  gray80
  2888.   gnuplot*line4Gray:  gray40
  2889.   gnuplot*line5Gray:  gray90
  2890.   gnuplot*line6Gray:  gray50
  2891.   gnuplot*line7Gray:  gray70
  2892.   gnuplot*line8Gray:  gray30
  2893.  Go Up 
  2894.  
  2895.  
  2896. ΓòÉΓòÉΓòÉ 3.67.5. line_resources ΓòÉΓòÉΓòÉ
  2897.  
  2898. gnuplot honors the following resources for setting the width (in pixels) of 
  2899. plot lines (shown here with their default values.)  0 or 1 means a minimal 
  2900. width line of 1 pixel width.  A value of 2 or 3 may improve the appearance of 
  2901. some plots. 
  2902.  
  2903.   gnuplot*borderWidth: 2
  2904.   gnuplot*axisWidth:   0
  2905.   gnuplot*line1Width:  0
  2906.   gnuplot*line2Width:  0
  2907.   gnuplot*line3Width:  0
  2908.   gnuplot*line4Width:  0
  2909.   gnuplot*line5Width:  0
  2910.   gnuplot*line6Width:  0
  2911.   gnuplot*line7Width:  0
  2912.   gnuplot*line8Width:  0
  2913.  
  2914. gnuplot honors the following resources for setting the dash style used for 
  2915. plotting lines.  0 means a solid line.  A two-digit number jk (j and k are >= 1 
  2916. and <= 9) means a dashed line with a repeated pattern of j pixels on followed 
  2917. by k pixels off.  For example, '16' is a "dotted" line with one pixel on 
  2918. followed by six pixels off.  More elaborate on/off patterns can be specified 
  2919. with a four-digit value.  For example, '4441' is four on, four off, four on, 
  2920. one off.  The default values shown below are for monochrome displays or 
  2921. monochrome rendering on color or grayscale displays.  For color displays, the 
  2922. default for each is 0 (solid line) except for axisDashes which defaults to a 
  2923. '16' dotted line. 
  2924.  
  2925.   gnuplot*borderDashes:   0
  2926.   gnuplot*axisDashes:    16
  2927.   gnuplot*line1Dashes:    0
  2928.   gnuplot*line2Dashes:   42
  2929.   gnuplot*line3Dashes:   13
  2930.   gnuplot*line4Dashes:   44
  2931.   gnuplot*line5Dashes:   15
  2932.   gnuplot*line6Dashes: 4441
  2933.   gnuplot*line7Dashes:   42
  2934.   gnuplot*line8Dashes:   13
  2935.  Go Up 
  2936.  
  2937.  
  2938. ΓòÉΓòÉΓòÉ 3.68. xlib ΓòÉΓòÉΓòÉ
  2939.  
  2940. The xlib terminal driver supports the X11 Windows System.  It generates 
  2941. gnulib_x11 commands.  set term x11 behaves similarly to set terminal xlib; set 
  2942. output "|gnuplot_x11".  xlib has no options, but see x11.  Go Up 
  2943.  
  2944.  
  2945. ΓòÉΓòÉΓòÉ 3.69. AUTHOR ΓòÉΓòÉΓòÉ
  2946.  
  2947. Autogenerated from *.trm files in gnuplot terminals subdirectory.  Go Up 
  2948.  
  2949.  
  2950. ΓòÉΓòÉΓòÉ 3.70. SEE ALSO ΓòÉΓòÉΓòÉ
  2951.  
  2952. Term::Gnuplot.