1 /* GNUPLOT - driver.h */
2 
3 /*[
4  * Copyright 1986 - 1993, 1998, 2004   Thomas Williams, Colin Kelley
5  *
6  * Permission to use, copy, and distribute this software and its
7  * documentation for any purpose with or without fee is hereby granted,
8  * provided that the above copyright notice appear in all copies and
9  * that both that copyright notice and this permission notice appear
10  * in supporting documentation.
11  *
12  * Permission to modify the software is granted, but not the right to
13  * distribute the complete modified source code.  Modifications are to
14  * be distributed as patches to the released version.  Permission to
15  * distribute binaries produced by compiling modified sources is granted,
16  * provided you
17  *   1. distribute the corresponding source modifications from the
18  *    released version in the form of a patch file along with the binaries,
19  *   2. add special version identification to distinguish your version
20  *    in addition to the base release version number,
21  *   3. provide your name and address as the primary contact for the
22  *    support of your modified version, and
23  *   4. retain our contact information in regard to use of the base
24  *    software.
25  * Permission to distribute the released version of the source code along
26  * with corresponding source modifications in the form of a patch file is
27  * granted with same provisions 2 through 4 for binary distributions.
28  *
29  * This software is provided "as is" without express or implied warranty
30  * to the extent permitted by applicable law.
31 ]*/
32 
33 
34 #ifndef TERM_DRIVER_H
35 #define TERM_DRIVER_H
36 
37 #include "syscfg.h"
38 
39 #include <stdio.h>
40 
41 /* functions provided by term.c */
42 
43 static void do_point(unsigned int x, unsigned int y, int number);
44 static void line_and_point(unsigned int x, unsigned int y, int number);
45 static int null_text_angle(int ang);
46 static int null_justify_text(enum JUSTIFY just);
47 static int null_scale(double x, double y);
48 static void options_null(void);
49 static void UNKNOWN_null(void);
50 /* static int set_font_null(const char *s);     */ /* unused */
51 #define set_font_null NULL
52 
53 extern FILE *gpoutfile;
54 extern struct termentry *term;
55 
56 /* for use by all drivers */
57 #define sign(x) ((x) >= 0 ? 1 : -1)
58 
59 /* abs as macro is now uppercase, there are conflicts with a few C compilers
60    that have abs as macro, even though ANSI defines abs as function
61    (int abs(int)). Most calls to ABS in term/ could be changed to abs if
62    they use only int arguments and others to fabs, but for the time being,
63    all calls are done via the macro */
64 #ifndef ABS
65 # define ABS(x) ((x) >= 0 ? (x) : -(x))
66 #endif /* ABS */
67 
68 #define NICE_LINE		0
69 #define POINT_TYPES		6
70 
71 #endif /* TERM_DRIVER_H */
72