Re: Getting tkined to work.

Thomas R. Benjamin (thomasb@austin.ibm.com)
Thu, 19 Sep 1996 10:48:32 -0500 (CDT)

I'm having the same problem on an RS6000/320 running AIX 4.1.4
with tcl7.5 and tk4.1. I posted a note to the list, and will
append Juergen's response.

By running the tkined wish script a line at a time, I found
the message was produced when this line was executed.

if {! [info exists views]} {
set views [EDITOR]
}

The error is produced by the script
/usr/local/lib/tkined1.4.1/library/Editor.tcl in proc Editor::toplevel .
When the line < wm iconbitmap $w icon > is commented out, the first
error is then produced by the follwing:

button $w.tools.node -bitmap machine -relief flat \
-command "Tool::Node $editor"

with error output -> <bitmap "machine" not found>

This line can be made to succeed by entering a full path for the
bitmap, including the .xbm suffix, and preceding it with @. In
that case, the error moves to the next button command with an
implicit bitmap reference.

This problem occured with the following environmental variables defined
and exported (Korn Shell):
TCLLIBPATH='/usr/local/lib/tkined1.4.1 /usr/local/lib/tnm2.1.1'
TCL_LIBRARY=/usr/local/lib/tcl7.5
TK_LIBRARY=/usr/local/lib/tk4.1

Also these lines were placed in /usr/local/lib/tcl7.5/init.tcl :
lappend auto_path /usr/local/lib
lappend auto_path /usr/local/lib/tnm2.1.1
lappend auto_path /usr/local/lib/tkined1.4.1

For some reason, tkined cannot find it's bitmaps. Tk can
find bitmaps, because the following wish script segment works:

button .b1 -bitmap question
button .b1 -bitmap @/usr/local/lib/tkined1.4.1/bitmaps/machine.xbm
pack .b1 .b2

Two questions. Because I feared my dynamic load setup was not
correct, I expicitly loaded tnm2.1.1.so and tkined1.4.1.so
immediately after the < wm withdraw . > statement. Was that the
wrong time, or does it even matter? Do I need to manipulate the
pkgIndex.tcl files produced by make, or can I assume they are
ready for use after make install?

Here is Juergen's rely to my original request. I may not have
implemented his suggestions correctly. As ever, thanks for the help.

Tom
====Juergen's reply====
The bitmap "icon" is defined in the tkined dynamic library which is
loaded from the "package require Tkined 1.4" command at the beginning
of the tkined script. This only works correctly if you use the
pgkIndex.tcl file which is created during the installation process.
(No guarantee that it works if you use a different setup since Tcl
delays loading of packages which is IMHO an error.)

Juergen
=====end of reply=====

====Terje Malmedal writes=====
>
>
> Hi, I am probably missing something obvious but...
>
> I can't get tkined from scotty 2.1.3 to work. scotty itself and the
> programs in ../lib/tnm2.1.3/examples all seem to work fine including
> mibtree.
>
> When I try to start tkined, however no window gets displayed.
>
> cornavin:~[534] /local/tcl/bin/tkined1.4.3
> bitmap "icon" not definedEnd of file
>
> The 'End of file' message is from a puts statement I put at the end of
> the tkined script.
>
> Platform is PowerPC AIX 4.1.4
>
> I am using Tcl7.1p1plus and Tk4.1p1plus(from
> http://www.nici.kun.nl/tkpvm/pluspatch.html)
>
> If anybody has any ideas it will be much appreciated.
> --
> - Terje
> malmedal@usit.uio.no
>

-- 
Thomas R. Benjamin
Integrated Systems and Solutions Corporation
Phone:  512.893.9359
E-Mail: thomasb@austin.ibm.com