emit_defaults(job);
}
+#if 0
static boolean node_in_view(GVJ_t *job, node_t * n)
{
boxf b;
return boxf_overlap(job->pageBoxClip, b);
}
+#endif
static boolean is_natural_number(char *sstr)
{
return FALSE;
}
-#if 0
-/* ND_bb(n) not set early enough to use in layout */
+#if 1
static boolean node_in_box(node_t *n, boxf b)
{
return boxf_overlap(ND_bb(n), b);
return;
if (node_in_layer(job, n->graph, n)
- && node_in_view(job, n)
+ && node_in_box(n, job->pageBoxClip)
&& (ND_state(n) != gvc->viewNum)) {
gvrender_comment(job, n->name);
gvrender_polyline(job, A, 3);
}
+#if 0
static boolean edge_in_view(GVJ_t *job, edge_t * e)
{
int i, j, np;
b.UR.y = lp->p.y + sy;
return boxf_overlap(job->pageBoxClip, b);
}
+#endif
void emit_edge_graphics(GVJ_t * job, edge_t * e)
{
gvrender_end_context(job);
}
-#if 0
-/* ED_spl(e).bb not set early enough to use in layout */
+#if 1
static boolean edge_in_box(edge_t *e, boxf b)
{
splines *spl;
char *s, *url = NULL, *label = NULL, *tooltip = NULL, *target = NULL;
textlabel_t *lab = NULL;
- if (! edge_in_view(job, e) || ! edge_in_layer(job, e->head->graph, e))
+ if (! edge_in_box(e, job->pageBoxClip) || ! edge_in_layer(job, e->head->graph, e))
return;
s = malloc(strlen(e->tail->name) + 2 + strlen(e->head->name) + 1);
char *str;
double sx, sy;
+ sx = job->width / (job->zoom * 2.);
+ sy = job->height / (job->zoom * 2.);
+ job->clip.UR.x = job->focus.x + sx + EPSILON;
+ job->clip.UR.y = job->focus.y + sy + EPSILON;
+ job->clip.LL.x = job->focus.x - sx - EPSILON;
+ job->clip.LL.y = job->focus.y - sy - EPSILON;
+
job->sg = g; /* current subgraph/cluster */
if (gvre) {
job->compscale.x = job->zoom * job->dpi / POINTS_PER_INCH;
job->compscale.y = job->compscale.x *
((job->render_features->flags & GVRENDER_Y_GOES_DOWN) ? -1.0 : 1.0);
- sx = job->width / (job->zoom * 2.);
- sy = job->height / (job->zoom * 2.);
- job->clip.UR.x = job->focus.x + sx + EPSILON;
- job->clip.UR.y = job->focus.y + sy + EPSILON;
- job->clip.LL.x = job->focus.x - sx - EPSILON;
- job->clip.LL.y = job->focus.y - sy - EPSILON;
-
/* render specific init */
if (gvre->begin_graph)
gvre->begin_graph(job, gvc->graphname);