]> granicus.if.org Git - graphviz/commitdiff
fix breakage to the non-cgraph version
authorellson <devnull@localhost>
Tue, 14 Oct 2008 23:23:07 +0000 (23:23 +0000)
committerellson <devnull@localhost>
Tue, 14 Oct 2008 23:23:07 +0000 (23:23 +0000)
lib/common/input.c
lib/common/macros.h
lib/common/types.h

index c56e99e97e0f8f23ce36e734a09612a9df1125f2..7418ae9e63eb2b9437cb7880a115c0f03f138bdc 100644 (file)
 #include "render.h"
 #include "htmltable.h"
 
-#ifdef WITH_CGRAPH
-#define SET_RANKDIR(g,rd) (GD_rankdir2(g) = rd)
-#else
-#define SET_RANKDIR(g,rd) ((g)->u.rankdir = (rd))
-#endif
-
 static char *usageFmt =
     "Usage: %s [-Vv?] [-(GNE)name=val] [-(KTlso)<val>] <dot files>\n";
 
@@ -974,7 +968,7 @@ void do_graph_label(graph_t * sg)
 #ifdef WITH_CGRAPH
        if (sg == agroot(sg))
 #else
-       if (sg == sg->root) {
+       if (sg == sg->root)
 #endif
            return;
 
index 3cbd6aa5b7e367696a11462bd96e1db0336173d4..3ce634576fa3d7a105e9185eecfa5cf3b5f9a65e 100644 (file)
 #define SET_CLUST_EDGE(g) (GD_flags(g) |= 1)
 #define EDGE_TYPE(g) (GD_flags(g) & (7 << 1))
 
+#ifdef WITH_CGRAPH
+#define SET_RANKDIR(g,rd) (GD_rankdir2(g) = rd)
+#else
+#define SET_RANKDIR(g,rd) ((g)->u.rankdir = (rd))
+#endif
+
 #ifndef streq
 #define streq(a,b)             (*(a)==*(b)&&!strcmp(a,b))
 #endif
index 24ecae0a4f710bb92e74f150fbd11be545191a34..b3e3a0a2a04ed2f83257fba9fb28c2c6abc446f7 100644 (file)
@@ -36,11 +36,6 @@ typedef unsigned char boolean;
 #include "gvcext.h"
 #include "pathgeom.h"
 #include "textpara.h"
-#ifdef WITH_CGRAPH
-#include "cgraph.h"
-#else
-#include "graph.h"
-#endif
 
 #ifdef __cplusplus
 extern "C" {
@@ -742,6 +737,12 @@ typedef enum {NATIVEFONTS,PSFONTS,SVGFONTS} fontname_kind;
 #define ED_tree_index(e) (e)->u.tree_index
 #define ED_weight(e) (e)->u.weight
 #define ED_xpenalty(e) (e)->u.xpenalty
+#endif
+
+#ifdef WITH_CGRAPH
+#include "cgraph.h"
+#else
+#include "graph.h"
 #endif
 
     typedef struct {