38 #define WIDTH_NORMAL 1
41 #define DIA_RESOLUTION 1.0
42 #define SCALE (DIA_RESOLUTION/15.0)
52 static char *sdarray =
"5,2";
54 static char *sdotarray =
"1,5";
55 static int GraphURL, ClusterURL, NodeURL, EdgeURL;
56 static char *op[] = {
"graph",
"node",
"edge",
"graph" };
65 static int onetime =
TRUE;
69 static graph_t *Curgraph, *Rootgraph;
85 static int dia_fputs(
char *
s)
92 return gzwrite(Zfile, s, (
unsigned) len);
106 static int dia_printf(
const char *format, ...)
112 va_start(argp, format);
113 #ifdef HAVE_VSNPRINTF
114 (void) vsnprintf(buf,
sizeof(buf), format, argp);
116 (void) vsprintf(buf, format, argp);
126 return gzwrite(Zfile, buf, (
unsigned) len);
132 #define SVG_COLORS_P 0
134 static int dia_comparestr(
const void *
s1,
const void *s2)
136 return strcmp(*(
char **) s1, *(
char **) s2);
139 static char *dia_resolve_color(
char *name)
143 static char *svg_known_colors[] = {
144 "aliceblue",
"antiquewhite",
"aqua",
"aquamarine",
"azure",
145 "beige",
"bisque",
"black",
"blanchedalmond",
"blue",
146 "blueviolet",
"brown",
"burlywood",
147 "cadetblue",
"chartreuse",
"chocolate",
"coral",
148 "cornflowerblue",
"cornsilk",
"crimson",
"cyan",
149 "darkblue",
"darkcyan",
"darkgoldenrod",
"darkgray",
150 "darkgreen",
"darkgrey",
"darkkhaki",
"darkmagenta",
151 "darkolivegreen",
"darkorange",
"darkorchid",
"darkred",
152 "darksalmon",
"darkseagreen",
"darkslateblue",
"darkslategray",
153 "darkslategrey",
"darkturquoise",
"darkviolet",
"deeppink",
154 "deepskyblue",
"dimgray",
"dimgrey",
"dodgerblue",
155 "firebrick",
"floralwhite",
"forestgreen",
"fuchsia",
156 "gainsboro",
"ghostwhite",
"gold",
"goldenrod",
"gray",
157 "green",
"greenyellow",
"grey",
158 "honeydew",
"hotpink",
"indianred",
159 "indigo",
"ivory",
"khaki",
160 "lavender",
"lavenderblush",
"lawngreen",
"lemonchiffon",
161 "lightblue",
"lightcoral",
"lightcyan",
"lightgoldenrodyellow",
162 "lightgray",
"lightgreen",
"lightgrey",
"lightpink",
163 "lightsalmon",
"lightseagreen",
"lightskyblue",
164 "lightslategray",
"lightslategrey",
"lightsteelblue",
165 "lightyellow",
"lime",
"limegreen",
"linen",
166 "magenta",
"maroon",
"mediumaquamarine",
"mediumblue",
167 "mediumorchid",
"mediumpurple",
"mediumseagreen",
168 "mediumslateblue",
"mediumspringgreen",
"mediumturquoise",
169 "mediumvioletred",
"midnightblue",
"mintcream",
170 "mistyrose",
"moccasin",
171 "navajowhite",
"navy",
"oldlace",
172 "olive",
"olivedrab",
"orange",
"orangered",
"orchid",
173 "palegoldenrod",
"palegreen",
"paleturquoise",
174 "palevioletred",
"papayawhip",
"peachpuff",
"peru",
"pink",
175 "plum",
"powderblue",
"purple",
176 "red",
"rosybrown",
"royalblue",
177 "saddlebrown",
"salmon",
"sandybrown",
"seagreen",
"seashell",
178 "sienna",
"silver",
"skyblue",
"slateblue",
"slategray",
179 "slategrey",
"snow",
"springgreen",
"steelblue",
180 "tan",
"teal",
"thistle",
"tomato",
"turquoise",
182 "wheat",
"white",
"whitesmoke",
183 "yellow",
"yellowgreen",
192 sizeof(svg_known_colors) /
sizeof(
char *),
193 sizeof(
char *), dia_comparestr) ==
NULL)) {
195 if (
streq(tok,
"transparent")) {
199 sprintf(buf,
"#%02x%02x%02x",
208 static void dia_reset(
void)
214 static void init_dia(
void)
232 rv.
x = PB.
LL.
x + p.
x * Scale + Offset.
x;
233 rv.
y = PB.
UR.
y - 1 - p.
y * Scale - Offset.
y;
235 rv.
x = PB.
UR.
x - 1 - p.
y * Scale - Offset.
x;
236 rv.
y = PB.
UR.
y - 1 - p.
x * Scale - Offset.
y;
246 rv.
x = PB.
LL.
x + p.
x * Scale + Offset.
x;
247 rv.
y = PB.
UR.
y - 1 - p.
y * Scale - Offset.
y;
249 rv.
x = PB.
UR.
x - 1 - p.
y * Scale - Offset.
x;
250 rv.
y = PB.
UR.
y - 1 - p.
x * Scale - Offset.
y;
258 dia_fputs(
" <dia:attribute name=\"border_color\">\n");
259 dia_printf(
" <dia:color val=\"%s\"/>\n",
261 dia_fputs(
" </dia:attribute>\n");
264 dia_fputs(
" <dia:attribute name=\"line_width\">\n");
265 dia_printf(
" <dia:real val=\"%g\"/>\n",
267 dia_fputs(
" </dia:attribute>\n");
270 dia_fputs(
" <dia:attribute name=\"line_style\">\n");
271 dia_printf(
" <dia:real val=\"%d\"/>\n", 1);
272 dia_fputs(
" </dia:attribute>\n");
275 dia_printf(
"stroke-dasharray:%s;", sdotarray);
280 static void dia_grstylefill(
context_t * cp,
int filled)
283 dia_fputs(
" <dia:attribute name=\"inner_color\">\n");
284 dia_printf(
" <dia:color val=\"%s\"/>\n",
286 dia_fputs(
" </dia:attribute>\n");
288 dia_fputs(
" <dia:attribute name=\"show_background\">\n");
289 dia_printf(
" <dia:boolean val=\"%s\"/>\n",
"true");
290 dia_fputs(
" </dia:attribute>\n");
294 static void dia_comment(
char *
str)
302 dia_begin_job(FILE * ofp,
graph_t * g,
const char **lib,
char *
info[],
point pages)
307 fd = dup(fileno(Output_file));
309 Zfile = gzdopen(fd,
"wb");
311 agerr(
AGERR,
"Error opening compressed output file\n");
316 "No support for compressed output. Not compiled with zlib.\n");
322 dia_printf(
"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n");
326 static void dia_end_job(
void)
343 (
"<dia:diagram xmlns:dia=\"http://www.lysator.liu.se/~alla/dia/\">\n");
344 dia_fputs(
" <dia:diagramdata>\n");
345 dia_fputs(
" <dia:attribute name=\"background\">\n");
346 dia_fputs(
" <dia:color val=\"#ffffff\"/>\n");
347 dia_fputs(
" </dia:attribute>\n");
348 dia_fputs(
" <dia:attribute name=\"paper\">\n");
349 dia_fputs(
" <dia:composite type=\"paper\">\n");
350 dia_fputs(
" <dia:attribute name=\"name\">\n");
351 dia_fputs(
" <dia:string>#A4#</dia:string>\n");
352 dia_fputs(
" </dia:attribute>\n");
353 dia_fputs(
" <dia:attribute name=\"tmargin\">\n");
354 dia_fputs(
" <dia:real val=\"2.8222\"/>\n");
355 dia_fputs(
" </dia:attribute>\n");
356 dia_fputs(
" <dia:attribute name=\"bmargin\">\n");
357 dia_fputs(
" <dia:real val=\"2.8222\"/>\n");
358 dia_fputs(
" </dia:attribute>\n");
359 dia_fputs(
" <dia:attribute name=\"lmargin\">\n");
360 dia_fputs(
" <dia:real val=\"2.8222\"/>\n");
361 dia_fputs(
" </dia:attribute>\n");
362 dia_fputs(
" <dia:attribute name=\"rmargin\">\n");
363 dia_fputs(
" <dia:real val=\"2.8222\"/>\n");
364 dia_fputs(
" </dia:attribute>\n");
365 dia_fputs(
" <dia:attribute name=\"is_portrait\">\n");
366 dia_fputs(
" <dia:boolean val=\"true\"/>\n");
367 dia_fputs(
" </dia:attribute>\n");
368 dia_fputs(
" <dia:attribute name=\"scaling\">\n");
369 dia_fputs(
" <dia:real val=\"1\"/>\n");
370 dia_fputs(
" </dia:attribute>\n");
371 dia_fputs(
" <dia:attribute name=\"fitto\">\n");
372 dia_fputs(
" <dia:boolean val=\"false\"/>\n");
373 dia_fputs(
" </dia:attribute>\n");
374 dia_fputs(
" </dia:composite>\n");
375 dia_fputs(
" </dia:attribute>\n");
376 dia_fputs(
" <dia:attribute name=\"grid\">\n");
377 dia_fputs(
" <dia:composite type=\"grid\">\n");
378 dia_fputs(
" <dia:attribute name=\"width_x\">\n");
379 dia_fputs(
" <dia:real val=\"1\"/>\n");
380 dia_fputs(
" </dia:attribute>\n");
381 dia_fputs(
" <dia:attribute name=\"width_y\">\n");
382 dia_fputs(
" <dia:real val=\"1\"/>\n");
383 dia_fputs(
" </dia:attribute>\n");
384 dia_fputs(
" <dia:attribute name=\"visible_x\">\n");
385 dia_fputs(
" <dia:int val=\"1\"/>\n");
386 dia_fputs(
" </dia:attribute>\n");
387 dia_fputs(
" <dia:attribute name=\"visible_y\">\n");
388 dia_fputs(
" <dia:int val=\"1\"/>\n");
389 dia_fputs(
" </dia:attribute>\n");
390 dia_fputs(
" </dia:composite>\n");
391 dia_fputs(
" </dia:attribute>\n");
392 dia_fputs(
" <dia:attribute name=\"guides\">\n");
393 dia_fputs(
" <dia:composite type=\"guides\">\n");
394 dia_fputs(
" <dia:attribute name=\"hguides\"/>\n");
395 dia_fputs(
" <dia:attribute name=\"vguides\"/>\n");
396 dia_fputs(
" </dia:composite>\n");
397 dia_fputs(
" </dia:attribute>\n");
398 dia_fputs(
" </dia:diagramdata>\n");
401 static void dia_end_graph(
void)
403 dia_printf(
"</dia:diagram>\n");
410 dia_begin_page(
graph_t * g,
point page,
double scale,
int rot,
416 Scale = scale *
SCALE;
421 dia_printf(
" <dia:layer name=\"Background\" visible=\"true\">\n");
424 static void dia_end_page(
void)
426 dia_fputs(
" </dia:layer>\n");
429 static void dia_begin_cluster(
graph_t * g)
431 dia_printf(
"<dia:group>\n");
435 static void dia_end_cluster(
void)
437 dia_printf(
"</dia:group>\n");
440 static void dia_begin_node(
node_t * n)
442 dia_printf(
"<dia:group>\n");
446 static void dia_end_node(
void)
448 dia_printf(
"</dia:group>\n");
451 static void dia_begin_edge(
edge_t * e)
456 static void dia_end_edge(
void)
461 static void dia_begin_context(
void)
464 cstk[SP + 1] = cstk[SP];
468 static void dia_end_context(
void)
476 static void dia_set_font(
char *name,
double size)
488 static void dia_set_pencolor(
char *name)
493 static void dia_set_fillcolor(
char *name)
498 static void dia_set_style(
char **
s)
504 while ((p = line = *s++)) {
505 if (
streq(line,
"solid"))
507 else if (
streq(line,
"dashed"))
509 else if (
streq(line,
"dotted"))
515 else if (
streq(line,
"setlinewidth")) {
520 }
else if (
streq(line,
"filled"))
522 else if (
streq(line,
"unfilled"))
526 "dia_set_style: unsupported style %s - ignoring\n",
534 static void dia_textpara(
point p, textpara_t * para)
541 switch (para->just) {
556 (
" <dia:object type=\"Standard - Text\" version=\"0\" id=\"%s\">\n",
558 dia_fputs(
" <dia:attribute name=\"text\">\n");
559 dia_fputs(
" <dia:composite type=\"text\">\n");
560 dia_fputs(
" <dia:attribute name=\"string\">\n");
561 dia_fputs(
" <dia:string>#");
563 dia_fputs(
"#</dia:string>\n");
564 dia_fputs(
" </dia:attribute>\n");
565 dia_fputs(
" <dia:attribute name=\"font\">\n");
566 dia_printf(
" <dia:font name=\"%s\"/>\n", cp->
fontfam);
567 dia_fputs(
" </dia:attribute>\n");
568 dia_fputs(
" <dia:attribute name=\"height\">\n");
569 dia_printf(
" <dia:real val=\"%g\"/>\n",
571 dia_fputs(
" </dia:attribute>\n");
572 dia_fputs(
" <dia:attribute name=\"pos\">\n");
573 dia_printf(
" <dia:point val=\"%g,%g\"/>\n", mp.
x, mp.
y);
574 dia_fputs(
" </dia:attribute>\n");
575 dia_fputs(
" <dia:attribute name=\"color\">\n");
576 dia_printf(
" <dia:color val=\"%s\"/>\n",
578 dia_fputs(
" </dia:attribute>\n");
579 dia_fputs(
" <dia:attribute name=\"alignment\">\n");
580 dia_printf(
" <dia:enum val=\"%d\"/>\n", anchor);
581 dia_fputs(
" </dia:attribute>\n");
582 dia_fputs(
" </dia:composite>\n");
583 dia_fputs(
" </dia:attribute>\n");
584 dia_fputs(
" <dia:attribute name=\"obj_pos\">\n");
585 dia_printf(
" <dia:point val=\"%g,%g\"/>\n", mp.
x, mp.
y);
586 dia_fputs(
" </dia:attribute>\n");
587 dia_fputs(
" <dia:attribute name=\"obj_bb\">\n");
588 dia_printf(
" <dia:rectangle val=\"%g,%g;%g,%g\"/>\n",
589 mp.
x - (Scale * (para->width) / 2.), mp.
y - 0.4,
590 mp.
x + (Scale * (para->width) / 2.), mp.
y + 0.4);
591 dia_fputs(
" </dia:attribute>\n");
592 dia_fputs(
" </dia:object>\n");
595 static void dia_ellipse(
point p,
int rx,
int ry,
int filled)
602 nodeId =
AGID(Curnode);
609 if (cstk[SP].pen ==
P_NONE) {
625 (
" <dia:object type=\"Standard - Ellipse\" version=\"0\" id=\"%d\">\n",
627 dia_fputs(
" <dia:attribute name=\"elem_corner\">\n");
628 dia_printf(
" <dia:point val=\"%g,%g\"/>\n", cp.
x - rp.
x,
630 dia_fputs(
" </dia:attribute>\n");
631 dia_fputs(
" <dia:attribute name=\"elem_width\">\n");
632 dia_printf(
" <dia:real val=\"%g\"/>\n", rp.
x + rp.
x);
633 dia_fputs(
" </dia:attribute>\n");
634 dia_fputs(
" <dia:attribute name=\"elem_height\">\n");
635 dia_printf(
" <dia:real val=\"%g\"/>\n", rp.
y + rp.
y);
636 dia_fputs(
" </dia:attribute>\n");
637 dia_fputs(
" <dia:attribute name=\"obj_pos\">\n");
638 dia_printf(
" <dia:point val=\"%g,%g\"/>\n", cp.
x - rp.
x,
640 dia_fputs(
" </dia:attribute>\n");
641 dia_fputs(
" <dia:attribute name=\"obj_bb\">\n");
642 dia_printf(
" <dia:rectangle val=\"%g,%g;%g,%g\"/>\n",
643 cp.
x - rp.
x - .11, cp.
y - rp.
y - .11, cp.
x + rp.
x + .11,
645 dia_fputs(
" </dia:attribute>\n");
646 dia_grstyle(&cstk[SP]);
647 dia_grstylefill(&cstk[SP], filled);
648 dia_fputs(
" </dia:object>\n");
661 }
else if (cp.
y == p.
y) {
666 }
else if (cp.
x < p.
x) {
671 }
else if (cp.
x > p.
x) {
684 int i = 0, j, sides, conn = 0, peripheries, z;
685 double xsize, ysize, mindist2 = 0.0,
dist2;
696 if (A_size < sides) {
704 for (j = 0; j < peripheries; j++) {
705 for (i = 0; i < sides; i++) {
706 P = vertices[i + j * sides];
707 A[i].
x = P.
x * xsize;
708 A[i].
y = P.
y * ysize;
723 if (
dist2 < mindist2) {
732 P.
x = (diaptf(A[z]).
x + diaptf(A[z + 1]).
x) / 2;
733 P.
y = (diaptf(A[z]).
y + diaptf(A[z + 1]).
y) / 2;
735 if (
dist2 < mindist2) {
747 dia_bezier(
point * A,
int n,
int arrow_at_start,
int arrow_at_end,
int filled)
749 int i, conn_h, conn_t;
750 pointf p, firstp = { 0, 0 }, llp = { 0, 0}, urp = { 0, 0};
755 if (cstk[SP].pen ==
P_NONE) {
761 (
" <dia:object type=\"Standard - BezierLine\" version=\"0\" id=\"%s\">\n",
763 dia_fputs(
" <dia:attribute name=\"bez_points\">\n");
764 for (i = 0; i < n; i++) {
767 llp = urp = firstp = p;
768 if (p.
x < llp.x || p.
y < llp.y)
770 if (p.
x > urp.x || p.
y > urp.y)
772 dia_printf(
" <dia:point val=\"%g,%g\"/>\n", p.
x, p.
y);
774 dia_fputs(
" </dia:attribute>\n");
775 dia_grstyle(&cstk[SP]);
776 dia_fputs(
" <dia:attribute name=\"obj_pos\">\n");
777 dia_printf(
" <dia:point val=\"%g,%g\"/>\n", firstp.
x, firstp.
y);
778 dia_fputs(
" </dia:attribute>\n");
779 dia_fputs(
" <dia:attribute name=\"obj_bb\">\n");
780 dia_printf(
" <dia:rectangle val=\"%g,%g;%g,%g\"/>\n",
781 llp.x - .11, llp.y - .11, urp.x + .11, urp.y + .11);
782 dia_fputs(
" </dia:attribute>\n");
785 conn_h = conn_t = -1;
793 if (arrow_at_start) {
794 dia_fputs(
" <dia:attribute name=\"start_arrow\">\n");
795 dia_fputs(
" <dia:enum val=\"3\"/>\n");
796 dia_fputs(
" </dia:attribute>\n");
797 dia_fputs(
" <dia:attribute name=\"start_arrow_length\">\n");
798 dia_fputs(
" <dia:real val=\"0.8\"/>\n");
799 dia_fputs(
" </dia:attribute>\n");
801 (
" <dia:attribute name=\"start_arrow_width\">\n");
802 dia_fputs(
" <dia:real val=\"0.8\"/>\n");
803 dia_fputs(
" </dia:attribute>\n");
806 dia_fputs(
" <dia:attribute name=\"end_arrow\">\n");
807 dia_fputs(
" <dia:enum val=\"3\"/>\n");
808 dia_fputs(
" </dia:attribute>\n");
809 dia_fputs(
" <dia:attribute name=\"end_arrow_length\">\n");
810 dia_fputs(
" <dia:real val=\"0.8\"/>\n");
811 dia_fputs(
" </dia:attribute>\n");
813 (
" <dia:attribute name=\"end_arrow_width\">\n");
814 dia_fputs(
" <dia:real val=\"0.8\"/>\n");
815 dia_fputs(
" </dia:attribute>\n");
818 dia_fputs(
" <dia:attribute name=\"conn_endpoints\">\n");
819 dia_printf(
" <dia:point val=\"%g,%g\"/>\n",
820 diapt(A[0]).x, diapt(A[0]).y);
821 dia_printf(
" <dia:point val=\"%g,%g\"/>\n",
822 diapt(A[n - 1]).x, diapt(A[n - 1]).y);
823 dia_fputs(
" </dia:attribute>\n");
824 dia_fputs(
" <dia:connections>\n");
827 if ((strcmp(shape_t,
"ellipse") == 0)
828 || (strcmp(shape_t,
"circle") == 0)
829 || (strcmp(shape_t,
"doublecircle") == 0)) {
836 }
else if (strcmp(shape_t,
"record") == 0) {
844 if ((strcmp(shape_t,
"ellipse") == 0)
845 || (strcmp(shape_t,
"circle") == 0)
846 || (strcmp(shape_t,
"doublecircle") == 0)) {
852 }
else if (strcmp(shape_t,
"record") == 0) {
860 if (arrow_at_start) {
862 (
" <dia:connection handle=\"0\" to=\"%d\" connection=\"%d\"/>\n",
865 (
" <dia:connection handle=\"%d\" to=\"%d\" connection=\"%d\"/>\n",
866 (n - 1),
AGID(tail), conn_t);
869 (
" <dia:connection handle=\"0\" to=\"%d\" connection=\"%d\"/>\n",
872 (
" <dia:connection handle=\"%d\" to=\"%d\" connection=\"%d\"/>\n",
873 (n - 1),
AGID(head), conn_h);
876 dia_fputs(
" </dia:connections>\n");
878 dia_fputs(
" </dia:object>\n");
883 static void dia_polygon(
point * A,
int n,
int filled)
886 pointf p, firstp = { 0, 0 }, llp = {
890 if (cstk[SP].pen ==
P_NONE) {
898 (
" <dia:object type=\"Standard - Polygon\" version=\"0\" id=\"%d\">\n",
906 (
" <dia:object type=\"Standard - Polygon\" version=\"0\" id=\"%s\">\n",
911 (
" <dia:object type=\"Standard - Polygon\" version=\"0\" id=\"%s\">\n",
915 dia_fputs(
" <dia:attribute name=\"poly_points\">\n");
916 for (i = 0; i < n; i++) {
919 llp = urp = firstp = p;
920 if (p.
x < llp.x || p.
y < llp.y)
922 if (p.
x > urp.x || p.
y > urp.y)
924 dia_printf(
" <dia:point val=\"%g,%g\"/>\n", p.
x, p.
y);
926 dia_fputs(
" </dia:attribute>\n");
927 dia_fputs(
" <dia:attribute name=\"obj_pos\">\n");
928 dia_printf(
" <dia:point val=\"%g,%g\"/>\n", firstp.
x, firstp.
y);
929 dia_fputs(
" </dia:attribute>\n");
930 dia_fputs(
" <dia:attribute name=\"obj_bb\">\n");
931 dia_printf(
" <dia:rectangle val=\"%g,%g;%g,%g\"/>\n",
932 llp.x - .11, llp.y - .11, urp.x + .11, urp.y + .11);
933 dia_fputs(
" </dia:attribute>\n");
934 dia_grstyle(&cstk[SP]);
935 dia_grstylefill(&cstk[SP], filled);
936 dia_fputs(
" </dia:object>\n");
939 static void dia_polyline(
point * A,
int n)
942 pointf p, firstp = { 0, 0 }, llp = {
946 if (cstk[SP].pen ==
P_NONE) {
951 (
" <dia:object type=\"Standard - PolyLine\" version=\"0\" id=\"%s\">\n",
953 dia_fputs(
" <dia:attribute name=\"poly_points\">\n");
954 for (i = 0; i < n; i++) {
957 llp = urp = firstp = p;
958 if (p.
x < llp.x || p.
y < llp.y)
960 if (p.
x > urp.x || p.
y > urp.y)
962 dia_printf(
"<dia:point val=\"%g,%g\"/>\n", p.
x, p.
y);
964 dia_fputs(
" </dia:attribute>\n");
965 dia_grstyle(&cstk[SP]);
966 dia_fputs(
" <dia:attribute name=\"obj_pos\">\n");
967 dia_printf(
" <dia:point val=\"%g,%g\"/>\n", firstp.
x, firstp.
y);
968 dia_fputs(
" </dia:attribute>\n");
969 dia_fputs(
" <dia:attribute name=\"obj_bb\">\n");
970 dia_printf(
" <dia:rectangle val=\"%g,%g;%g,%g\"/>\n",
971 llp.x - .11, llp.y - .11, urp.x + .11, urp.y + .11);
972 dia_fputs(
" </dia:attribute>\n");
973 dia_fputs(
" </dia:object>\n");
980 if (cstk[SP].pen ==
P_NONE) {
987 imagefile =
agget(Curnode,
"shapefile");
993 dia_polygon(A, n, filled);
1000 dia_begin_job, dia_end_job,
1001 dia_begin_graph, dia_end_graph,
1002 dia_begin_page, dia_end_page,
1004 dia_begin_cluster, dia_end_cluster,
1007 dia_begin_node, dia_end_node,
1008 dia_begin_edge, dia_end_edge,
1009 dia_begin_context, dia_end_context,
1011 dia_set_font, dia_textpara,
1012 dia_set_pencolor, dia_set_fillcolor, dia_set_style,
1013 dia_ellipse, dia_polygon,
1014 dia_bezier, dia_polyline,
void s1(graph_t *, node_t *)
#define ALLOC(size, ptr, type)
CGRAPH_API int agisdirected(Agraph_t *g)
int agerr(agerrlevel_t level, const char *fmt,...)
char * agget(void *obj, char *name)
CGRAPH_API Agnode_t * agtail(Agedge_t *e)
struct context_t context_t
int box_connection(node_t *n, pointf p)
CGRAPH_API Agnode_t * aghead(Agedge_t *e)
char * xml_string(char *s)
CGRAPH_API char * agnameof(void *)
int ellipse_connection(pointf cp, pointf p)
COORD dist2(Ppoint_t, Ppoint_t)
if(aagss+aagstacksize-1<=aagssp)
int colorxlate(char *str, gvcolor_t *color, color_type_t target_type)
char * canontoken(char *str)