From: John Ellson Date: Mon, 21 Oct 2013 14:44:41 +0000 (-0400) Subject: remove calls to reset_layout - no longer needed X-Git-Tag: 2.38.0~234^2~5 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b308f6fce6e5143c8b0d92529c2f4fb561c529bf;p=graphviz remove calls to reset_layout - no longer needed --- diff --git a/tclpkg/tcldot/tcldot-edgecmd.c b/tclpkg/tcldot/tcldot-edgecmd.c index a25908af6..6e8351b0e 100644 --- a/tclpkg/tcldot/tcldot-edgecmd.c +++ b/tclpkg/tcldot/tcldot-edgecmd.c @@ -46,7 +46,6 @@ int edgecmd(ClientData clientData, Tcl_Interp * interp, if ((c == 'd') && (strncmp(argv[1], "delete", length) == 0)) { deleteEdge(gctx, g, e); - reset_layout(gvc, g); return TCL_OK; } else if ((c == 'l') @@ -121,7 +120,6 @@ int edgecmd(ClientData clientData, Tcl_Interp * interp, } setedgeattributes(agroot(g), e, &argv[2], argc - 2); } - reset_layout(gvc, g); return TCL_OK; } else if ((c == 's') && (strncmp(argv[1], "showname", length) == 0)) { diff --git a/tclpkg/tcldot/tcldot-graphcmd.c b/tclpkg/tcldot/tcldot-graphcmd.c index 95d7932c1..1a2efad3c 100644 --- a/tclpkg/tcldot/tcldot-graphcmd.c +++ b/tclpkg/tcldot/tcldot-graphcmd.c @@ -78,7 +78,6 @@ int graphcmd(ClientData clientData, Tcl_Interp * interp, e = agedge(g, tail, head, NULL, 1); Tcl_AppendResult(interp, obj2cmd(e), NULL); setedgeattributes(agroot(g), e, &argv[4], argc - 4); - reset_layout(gvc, g); return TCL_OK; } else if ((c == 'a') && (strncmp(argv[1], "addnode", length) == 0)) { @@ -92,7 +91,6 @@ int graphcmd(ClientData clientData, Tcl_Interp * interp, } Tcl_AppendResult(interp, obj2cmd(n), NULL); setnodeattributes(agroot(g), n, &argv[i], argc - i); - reset_layout(gvc, g); return TCL_OK; } else if ((c == 'a') @@ -112,7 +110,6 @@ int graphcmd(ClientData clientData, Tcl_Interp * interp, i = 2; } setgraphattributes(sg, &argv[i], argc - i); - reset_layout(gvc, g); return TCL_OK; } else if ((c == 'c') && (strncmp(argv[1], "countnodes", length) == 0)) { @@ -126,7 +123,6 @@ int graphcmd(ClientData clientData, Tcl_Interp * interp, return TCL_OK; } else if ((c == 'd') && (strncmp(argv[1], "delete", length) == 0)) { - reset_layout(gvc, g); deleteGraph(gctx, g); return TCL_OK; @@ -443,7 +439,6 @@ int graphcmd(ClientData clientData, Tcl_Interp * interp, } setgraphattributes(g, argv2, argc2); Tcl_Free((char *) argv2); - reset_layout(gvc, g); } if (argc == 4 && strcmp(argv[2], "viewport") == 0) { /* special case to allow viewport to be set without resetting layout */ @@ -456,7 +451,6 @@ int graphcmd(ClientData clientData, Tcl_Interp * interp, return TCL_ERROR; } setgraphattributes(g, &argv[2], argc - 2); - reset_layout(gvc, g); } return TCL_OK; @@ -484,7 +478,6 @@ int graphcmd(ClientData clientData, Tcl_Interp * interp, } setedgeattributes(g, NULL, &argv[2], argc - 2); } - reset_layout(gvc, g); return TCL_OK; } else if ((c == 's') @@ -511,7 +504,6 @@ int graphcmd(ClientData clientData, Tcl_Interp * interp, } setnodeattributes(g, NULL, &argv[2], argc - 2); } - reset_layout(gvc, g); return TCL_OK; } else if ((c == 's') && (strncmp(argv[1], "showname", length) == 0)) { diff --git a/tclpkg/tcldot/tcldot-nodecmd.c b/tclpkg/tcldot/tcldot-nodecmd.c index 764f985cf..768196ede 100644 --- a/tclpkg/tcldot/tcldot-nodecmd.c +++ b/tclpkg/tcldot/tcldot-nodecmd.c @@ -65,12 +65,10 @@ int nodecmd(ClientData clientData, Tcl_Interp * interp, e = agedge(g, n, head, NULL, 1); Tcl_AppendResult(interp, obj2cmd(e), NULL); setedgeattributes(agroot(g), e, &argv[3], argc - 3); - reset_layout(gvc, g); return TCL_OK; } else if ((c == 'd') && (strncmp(argv[1], "delete", length) == 0)) { deleteNode(gctx, g, n); - reset_layout(gvc, g); return TCL_OK; } else if ((c == 'f') && (strncmp(argv[1], "findedge", length) == 0)) { @@ -180,7 +178,6 @@ int nodecmd(ClientData clientData, Tcl_Interp * interp, } setnodeattributes(g, n, &argv[2], argc - 2); } - reset_layout(gvc, g); return TCL_OK; } else if ((c == 's') && (strncmp(argv[1], "showname", length) == 0)) { diff --git a/tclpkg/tcldot/tcldot.h b/tclpkg/tcldot/tcldot.h index b096030a9..8415c0e84 100644 --- a/tclpkg/tcldot/tcldot.h +++ b/tclpkg/tcldot/tcldot.h @@ -117,4 +117,3 @@ extern size_t Tcldot_string_writer(GVJ_t *job, const char *s, size_t len); extern size_t Tcldot_channel_writer(GVJ_t *job, const char *s, size_t len); extern void tcldot_layout(GVC_t *gvc, Agraph_t * g, char *engine); -extern void reset_layout(GVC_t *gvc, Agraph_t * sg);