Number: 1779
Title: tcldot package not drawing to canvas or returning string
Submitter: Kevin
Date: Mon Oct 5 02:19:25 2009
Subsys: Tcl/Tk utilities
Version: 2.20.2
System: x86-Linux-Ubuntu 9.04
Severity: major
Example as in documentation fails to draw on canvas as render, nor does render return a string.

Example: starting wish8.5 here is a console session

> > wish8.5
% package require Tcldot
% set c [canvas .c] ; pack $c
% set g [dotnew digraph rankdir LR]
% $g setnodeattribute style filled color white
% [$g addnode Hello] addedge [$g addnode World!]
% $g layout
% set cmd [$g render]
# Generated by tcldot version 2.20.2 (Mon Mar 30 10:11:53 UTC 2009)
# For user: (kevin) kevin,,,
# Title: graph0 Pages: 1
# Hello
$c create oval 6.75 53.33 99.92 5.33 -fill white -width 1 -outline white -tags {id1 node}
$c create text 53.33 29.67 -text {Hello} -fill black -font {Times-Roman 14} -state disabled -tags {id1 node label}
# World!
$c create oval 149.63 53.33 266.37 5.33 -fill white -width 1 -outline white -tags {id2 node}
$c create text 208 29.67 -text {World!} -fill black -font {Times-Roman 14} -state disabled -tags {id2 node label}
# Hello->World!
$c create line 101.33 29.33 112 29.33 124 29.33 136 29.33 -fill black -width 1 -smooth bezier -state disabled -tags {id1 edge}
$c create polygon 136 24.67 149.33 29.33 136 34 -fill black -width 1 -outline black -state disabled -tags {id1 edge}
% puts $cmd

% ------

What we see is the $cmd variable is empty. its seems that the function is not returning a string, it just prints to the console. Similarly, 'eval [$g render]' draws nothing, because the command string prints to console and is not returned.

Neither does '$g render $c' draw to canvas, it just prints string of commands to console.

Perhaps tcl is being compiled without USE_TCL_STUBS enabled?

Any advice on what is needed to get tcldot running on a MacOSX?
Owner: ellson
Status: *