~ubuntu-branches/ubuntu/lucid/graphviz/lucid-security

« back to all changes in this revision

Viewing changes to dotneato/common/const.h

  • Committer: Bazaar Package Importer
  • Author(s): Stephen M Moraco
  • Date: 2002-02-05 18:52:12 UTC
  • Revision ID: james.westby@ubuntu.com-20020205185212-8i04c70te00rc40y
Tags: upstream-1.7.16
ImportĀ upstreamĀ versionĀ 1.7.16

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
    This software may only be used by you under license from AT&T Corp.
 
3
    ("AT&T").  A copy of AT&T's Source Code Agreement is available at
 
4
    AT&T's Internet website having the URL:
 
5
    <http://www.research.att.com/sw/tools/graphviz/license/source.html>
 
6
    If you received this software without first entering into a license
 
7
    with AT&T, you have an infringing copy of this software and cannot use
 
8
    it without violating AT&T's intellectual property rights.
 
9
*/
 
10
 
 
11
#ifndef PI
 
12
#ifdef M_PI
 
13
#define PI M_PI
 
14
#else
 
15
#define PI 3.14159265358979323846
 
16
#endif
 
17
#endif
 
18
 
 
19
#define SMALLBUF        128
 
20
#define LPAREN          '('
 
21
#define RPAREN          ')'
 
22
#define LBRACE          '{'
 
23
#define RBRACE          '}'
 
24
 
 
25
/*      node,edge types */
 
26
#define         NORMAL          0               /* an original input node */
 
27
#define         VIRTUAL         1               /* virtual nodes in long edge chains */
 
28
#define         SLACKNODE       2               /* encode edges in node position phase */
 
29
#define         REVERSED        3               /* reverse of an original edge */
 
30
#define         FLATORDER       4               /* for ordered edges */
 
31
#define         CLUSTER_EDGE 5          /* for ranking clusters */
 
32
#define         IGNORED         6               /* concentrated multi-edges */
 
33
 
 
34
/* collapsed node classifications */
 
35
#define         NOCMD           0               /* default */
 
36
#define         SAMERANK        1               /* place on same rank */
 
37
#define         MINRANK         2               /* place on "least" rank */
 
38
#define         SOURCERANK      3               /* strict version of MINRANK */
 
39
#define         MAXRANK         4               /* place on "greatest" rank */
 
40
#define         SINKRANK        5               /* strict version of MAXRANK */
 
41
#define         LEAFSET         6               /* set of collapsed leaf nodes */
 
42
#define         CLUSTER         7               /* set of clustered nodes */
 
43
 
 
44
/* type of cluster rank assignment */
 
45
#define         LOCAL           100
 
46
#define         GLOBAL          101
 
47
#define         NOCLUST         102
 
48
 
 
49
/* default attributes */
 
50
#define         DEFAULT_COLOR           "black"
 
51
#define         DEFAULT_FONTSIZE        14.0
 
52
#define         DEFAULT_LABEL_FONTSIZE  11.0 /* for head/taillabel */
 
53
#define         MIN_FONTSIZE            1.0
 
54
#define         DEFAULT_FONTNAME        "Times-Roman"
 
55
#define         DEFAULT_FILL            "lightgrey"
 
56
#ifdef _UWIN
 
57
#ifndef DEFAULT_FONTPATH
 
58
#define         DEFAULT_FONTPATH        "/win/fonts"
 
59
#endif
 
60
#else
 
61
#ifndef MSWIN32
 
62
#ifndef DEFAULT_FONTPATH
 
63
#define         DEFAULT_FONTPATH        "/usr/share/ttf:/usr/local/share/ttf:/usr/share/fonts/ttf:/usr/local/share/fonts/ttf:/usr/lib/fonts:/usr/local/lib/fonts:/usr/lib/fonts/ttf:/usr/local/lib/fonts/ttf:/usr/common/graphviz/lib/fonts/ttf:/windows/fonts:/dos/windows/fonts:/usr/add-on/share/ttf:."
 
64
#endif
 
65
#else
 
66
#ifndef DEFAULT_FONTPATH
 
67
#define         DEFAULT_FONTPATH        "C:/WINDOWS/FONTS;C:/WINNT/Fonts;C:/winnt/fonts"
 
68
#endif
 
69
#endif
 
70
#endif
 
71
#define         LINESPACING             1.15
 
72
 
 
73
#define         DEFAULT_NODEHEIGHT      0.5
 
74
#define         MIN_NODEHEIGHT          0.02
 
75
#define         DEFAULT_NODEWIDTH       0.75
 
76
#define         MIN_NODEWIDTH           0.01
 
77
#define         DEFAULT_NODESHAPE       "ellipse"
 
78
#define         NODENAME_ESC            "\\N"
 
79
 
 
80
#define         DEFAULT_NODESEP 0.25
 
81
#define         MIN_NODESEP             0.02    
 
82
#define         DEFAULT_RANKSEP 0.5
 
83
#define         MIN_RANKSEP             0.02
 
84
 
 
85
/* default margin for paged formats such as PostScript */
 
86
#define         DEFAULT_MARGIN  36
 
87
 
 
88
/* default margin for embedded formats such as PNG */
 
89
#define         DEFAULT_EMBED_MARGIN_X  10
 
90
#define         DEFAULT_EMBED_MARGIN_Y  2
 
91
 
 
92
#define         DEFAULT_PAGEHT  792
 
93
#define         DEFAULT_PAGEWD  612
 
94
 
 
95
#define         SELF_EDGE_SIZE  18
 
96
#define         MC_SCALE                256     /* for mincross */
 
97
 
 
98
#define         ARROW_LENGTH    10
 
99
#define         ARROW_WIDTH             5
 
100
/* added by vladimir */
 
101
#define         ARROW_INV_LENGTH        6
 
102
#define         ARROW_INV_WIDTH         7
 
103
#define         ARROW_DOT_RADIUS        2
 
104
#define         PORT_LABEL_DISTANCE     10
 
105
#define         PORT_LABEL_ANGLE        -25 /* degrees; pos is CCW, neg is CW */
 
106
 
 
107
/* added by vladimir */
 
108
/* arrow types */
 
109
#define ARR_NONE         0
 
110
#define ARR_NORM         1
 
111
#define ARR_INV          2
 
112
#define ARR_DOT          4
 
113
#define ARR_ODOT         8
 
114
#define ARR_INVDOT       (ARR_INV|ARR_DOT)
 
115
#define ARR_INVODOT      (ARR_INV|ARR_ODOT)
 
116
 
 
117
/* sides (e.g. of cluster margins) */
 
118
#define         BOTTOM_IX       0
 
119
#define         RIGHT_IX        1
 
120
#define         TOP_IX          2
 
121
#define         LEFT_IX         3
 
122
 
 
123
/* sides of boxes for SHAPE_path */
 
124
#define         BOTTOM          (1<<BOTTOM_IX)
 
125
#define         RIGHT           (1<<RIGHT_IX)
 
126
#define         TOP                     (1<<TOP_IX)
 
127
#define         LEFT            (1<<LEFT_IX)
 
128
 
 
129
/* output languages */
 
130
#define         ATTRIBUTED_DOT  0               /* default */
 
131
#define         POSTSCRIPT      1
 
132
#define         HPGL            2
 
133
#define         PCL             3
 
134
#define         MIF             4
 
135
#define         PIC_format      5               /* PIC used by compiler for 
 
136
                                        Position Independent Code */
 
137
#define         PLAIN           6
 
138
#define         PLAIN_EXT       7
 
139
 
 
140
#define         GD              8               /* libgd bitmap format */
 
141
#define         GD2             9               /* libgd bitmap format */
 
142
#define         GIF             10              /* libgd bitmap format */
 
143
#define         JPEG            11              /* libgd bitmap format */
 
144
#define         PNG             12              /* libgd bitmap format */
 
145
#define         WBMP            13              /* libgd bitmap format */
 
146
#define         XBM             14              /* libgd bitmap format */
 
147
 
 
148
#define         ISMAP           15              /* oldstyle map file for httpd servers */
 
149
#define         IMAP            16              /* apache map file for httpd servers */
 
150
#define         VRML            17
 
151
#define         VTX             18
 
152
#define         METAPOST        19
 
153
#define         FIG             20
 
154
#define         SVG             21      /* Structured Vector Graphics */
 
155
#define         SVGZ            22      /* compressed SVG */
 
156
#define         CANONICAL_DOT   23      /* wanted for tcl/tk version */
 
157
 
 
158
/* for clusters */
 
159
#define         CL_BACK         10              /* cost of backward pointing edge */
 
160
#define         CL_OFFSET       8               /* margin of cluster box in PS points */
 
161
#ifndef DOS
 
162
#define         CL_CROSS        1000    /* cost of cluster skeleton edge crossing */
 
163
#else
 
164
#define         CL_CROSS        100             /* avoid 16 bit overflow */
 
165
#endif
 
166
 
 
167
/* for graph server */
 
168
#define         SERVER_NN       200
 
169
#define         SERVER_NE       500
 
170
 
 
171
/* for neato */
 
172
#define NDIM            2
 
173
#define Spring_coeff    1.0
 
174
#define MYHUGE          (1.0e+37)