Graphviz Issue Tracker - graphviz
View Issue Details
0002277graphvizTcl/Tk Utilitiespublic2013-04-17 17:232014-12-19 08:53
AndrewStein 
ellson 
highcriticalalways
resolvedfixed 
MacOSXMtn Lion
patch applied
2.30.1
0002277: render no longer produces vaild tk tags.
According to the tcldot man page, the tags produced by render "take one of two forms: text items are tagged with 0<handle> and shapes and lines are rendered with 1<handle>." This was the case in 2.28, but is no longer the case in 2.30.1.

In 2.30.1 (see below) the handles are in the form graph0xHHHHHHHHHHHH, but the tags are in the form 0graphN, where H is a hex digit and N is a number.

> tclsh
% lappend auto_path /usr/local/lib/graphviz/tcl
/System/Library/Frameworks/Tcl.framework/Versions/8.5/Resources/Scripts /System/Library/Frameworks/Tcl.framework/Versions/8.5/Resources /usr/lib ~/Library/Tcl /Library/Tcl /System/Library/Tcl /System/Library/Tcl/8.5 ~/Library/Frameworks /Library/Frameworks /System/Library/Frameworks /usr/local/lib/graphviz/tcl
% package require Tcldot
2.30.1
% set g [dotnew digraph label Graph]
graph0x7fca43906520
% set sg [$g addsubgraph clusterX label SubGraph]
graph0x7fca41e0e630
% set n [$sg addnode label Node]
node0x7fca43907370
% $g render
# Generated by graphviz version 2.30.1 (20130221.2233)
# Pages: 1
$c create text 69.33 144.3 -text {Graph} -fill black -font {"Times" 14} -tags {0graph label-1}
$c create polygon 16 117.33 16 16 122.67 16 122.67 117.33 -fill "" -width 1 -outline black -tags {1graph1}
$c create text 69.33 32.3 -text {SubGraph} -fill black -font {"Times" 14} -tags {0graph1}
$c create oval 27.43 106.67 111.24 58.67 -fill white -width 1 -outline black -tags {1node1}
$c create text 69.33 82.43 -text {Node} -fill black -font {"Times" 14} -tags {0node1}

My code expects tags named 0graph0x7fca43906520, 1graph0x7fca41e0e630, 1node0x7fca43907370. The actual tags are named 0graph, 1graph1, 1node1.
As far as I can see there is no way for me to retrive the tag from the handle. This is the reason I have marked the severity as "critical"
No tags attached.
patch graphviz-2.38.0.patch (2,509) 2014-12-09 04:23
http://www.graphviz.org/mantisbt/file_download.php?file_id=419&type=bug
Issue History
2013-04-17 17:23AndrewSteinNew Issue
2013-04-17 17:43AndrewSteinNote Added: 0000332
2014-12-09 04:23csanchezdllFile Added: graphviz-2.38.0.patch
2014-12-09 04:25csanchezdllNote Added: 0000856
2014-12-19 08:53ellsonFIX-COMMENT => patch applied
2014-12-19 08:53ellsonStatusnew => resolved
2014-12-19 08:53ellsonResolutionopen => fixed
2014-12-19 08:53ellsonAssigned To => ellson

Notes
(0000332)
AndrewStein   
2013-04-17 17:43   
This is with the graphviz package downloaded from http://www.graphviz.org/Download_macos.php [^] for mountain lion
(0000856)
csanchezdll   
2014-12-09 04:25   
I have created a pull request on GitHub addressing the issue. Also uploaded a patch here (to be applied over 2.38) to be used meanwhile.