summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2009-06-28 22:46:26 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2009-06-28 22:46:26 (GMT)
commit1cb0bfdc11dc46a2bc2fd6dfb0aa32d0f4bf0fe1 (patch)
tree6579e29b3b843a7488e114f8cbf710d86c77b47b /src
parent33c1281b6a4e46e94daa3d165e32024f7d85d856 (diff)
Improved Graphviz coordinates.
git-svn-id: svn://svn.gna.org/svn/chrysalide/trunk@83 abbe820e-26c8-41b2-8c08-b7b2b41f8b0a
Diffstat (limited to 'src')
-rw-r--r--src/graph/dot.c6
-rw-r--r--src/graph/node.c6
2 files changed, 7 insertions, 5 deletions
diff --git a/src/graph/dot.c b/src/graph/dot.c
index e4ee38c..9f8e3b3 100644
--- a/src/graph/dot.c
+++ b/src/graph/dot.c
@@ -199,7 +199,7 @@ GtkLinkRenderer **create_links_from_graph_layout(const graph_layout *layout, siz
{
lines = ED_spl(eiter);
- printf("edge == %p\n", eiter);
+ //printf("edge == %p\n", eiter);
points = NULL;
points_count = 0;
@@ -213,14 +213,16 @@ GtkLinkRenderer **create_links_from_graph_layout(const graph_layout *layout, siz
points[points_count + k].x = lines->list[i].list[k].x;
points[points_count + k].y = height - lines->list[i].list[k].y;
+ /*
printf(" ... ( %d ; %d)\n",
lines->list[i].list[k].x, height - lines->list[i].list[k].y);
+ */
}
points_count += lines->list[i].size;
- printf(" ...\n");
+ //printf(" ...\n");
}
diff --git a/src/graph/node.c b/src/graph/node.c
index 8432476..e6427d8 100644
--- a/src/graph/node.c
+++ b/src/graph/node.c
@@ -177,7 +177,7 @@ GGraphNode *g_graph_node_new(GtkBinView *view)
}
-#include <math.h>
+
/******************************************************************************
* *
* Paramètres : node = intermédiaire à consulter. *
@@ -208,10 +208,10 @@ char *g_graph_node_register_for_dot(const GGraphNode *node, char *cmds)
requisition.width / G_GRAPH_NODE_GET_CLASS(node)->dpi_x,
requisition.height / G_GRAPH_NODE_GET_CLASS(node)->dpi_y);
- snprintf(buffer, 128, ", width=\"%g\"", round(requisition.width / G_GRAPH_NODE_GET_CLASS(node)->dpi_x) + 1.0);
+ snprintf(buffer, 128, ", width=\"%g\"", requisition.width / G_GRAPH_NODE_GET_CLASS(node)->dpi_x);
cmds = stradd(cmds, buffer);
- snprintf(buffer, 128, ", height=\"%g\"", round(requisition.height / G_GRAPH_NODE_GET_CLASS(node)->dpi_y) + 1.0);
+ snprintf(buffer, 128, ", height=\"%g\"", requisition.height / G_GRAPH_NODE_GET_CLASS(node)->dpi_y);
cmds = stradd(cmds, buffer);
cmds = stradd(cmds, "];\n");