home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Usenet 1994 October
/
usenetsourcesnewsgroupsinfomagicoctober1994disk1.iso
/
answers
/
tcl-faq
/
part1
next >
Wrap
Text File
|
1994-09-28
|
39KB
|
884 lines
Newsgroups: comp.lang.tcl,comp.answers,news.answers
Path: bloom-beacon.mit.edu!hookup!yeshua.marcam.com!news.kei.com!eff!wariat.org!malgudi.oar.net!chemabs!lvirden
From: lvirden@cas.org (Larry W. Virden)
Subject: FAQ: comp.lang.tcl Frequently Asked Questions (1/5)
(Last updated: July 26, 1994)
Message-ID: <tcl.p1_780761786@cas.org>
Followup-To: comp.lang.tcl
Summary: A regular posting of the comp.lang.tcl Frequently Asked Questions
(FAQ) and their answers. This is the first of five parts.
This part introduces Tcl and Tk and discusses documentation, etc.
Originator: lvirden@cas.org
Keywords: tcl, extended tcl, tk, expect
Sender: lvirden@cas.org
Supersedes: <tcl.p1_778352339@cas.org>
Reply-To: lvirden@cas.org (Larry W. Virden)
Organization: Chemical Abstracts Service
Date: Wed, 28 Sep 1994 14:16:31 GMT
Approved: news-answers-request@MIT.Edu
Expires: Wed, 9 Nov 1994 14:16:26 GMT
X-Url: http://www.cis.ohio-state.edu/hypertext/faq/usenet/tcl-faq/part1/faq.html
Lines: 860
Xref: bloom-beacon.mit.edu comp.lang.tcl:18134 comp.answers:7483 news.answers:26433
Archive-name: tcl-faq/part1
Version: 6.0
Last-modified: August 12, 1994
For more information concerning Tcl (see "tcl-faq/part2"),
(see "tcl-faq/part3"), (see "tcl-faq/part4"), or (see "tcl-faq/part5").
Also (see "tcl-faq/commercial-uses"), (see "tcl-faq/usage"),
(see "tcl-faq/bibliography").
Index of questions:
I. Origin of the comp.lang.tcl FAQ information and
to whom do I contact for more information about the FAQ?
II. What is Tcl? Tk? Extended Tcl? Rush? What is Tcl _not_?
III. Do these packages run on my machine?
A. Unix
B. MacOS
C. INTEL DOS-like systems
D. VMS
E. AmigaDOS
F. NeXT
G. Other
IV. Other than C, What languages can talk to tcl/tk?
A. Shell
B. C++
C. Modula-3
D. Eiffel
E. Ada
F. Perl
G. Prolog
H. Other
V. What training material is available?
A. Training courses, materials, etc.
B. Time-related seminars, conferences, sessions.
VI. Where do I report problems, bugs, or enhancements about Tcl - or -
what is comp.lang.tcl?
End of FAQ Index
----------------------------------------------------------------------
------------------------------
From: FAQ General information
Subject: -I- Origin of the comp.lang.tcl FAQ information.
The information in this set of FAQs comes from several sources. The
primary source of information is the group itself - I spend (much too
much) time each month culling through what I feel are some of the best
answers, gathering up new information on ports, etc. and adding it
here. I also gather new application information and add it as
best I can. The next most predominant source of information comes from
the authors of the various software packages. Finally, a small amount
comes from my personal experiences.
The primary location for the commercial use of Tcl FAQ is
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/docs/tcl-commercial-faq.gz>.
The author is gwl@cpu.com (Gerald W. Lester). This FAQ contains information
either about commercial products which incorporate Tcl as a part of
them or firms which teach about Tcl and Tk in some manner.
The Japanese translation of the comp.lang.tcl FAQ can be
located at
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/docs/tcl-faq-j5.3.tar.gz>.
This file contains Japanese EUC-Kanji codes. Contact
taguchi@fox.aic.co.jp (Taguchi Takeshi - Father of Japanese translation of FAQ)
for more information.
Three new general FAQs are in progress. These are spin-offs
from this original source document. The first will contain a bibliography
of published material related to Tcl, and will be managed by
glv@utdallas.edu (Glenn Vanderburg). (See "tcl-faq/bibliography/part1")
or ftp it at
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/docs/tcl-faq-bib.gz>.
The second FAQ will contain the series of Tcl-related questions
and answers and is managed by joe@morton.rain.com (Joe Moss).
(See "tcl-faq/tk-Q-and-A/part1") or find it at
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/docs/tcl-Q-and-A.p1.gz>.
The third will contain Tk-related questions and answers and
is managed by tja@cpu.com (Thomas J. Accardo). You can
(see "tcl-faq/tk.Q-and-A/part1") or find it
at <URL:ftp://harbor.ecn.purdue.edu/pub/tcl/docs/tk.Q-and-A.p1.gz>
If you have corrections, enhancements, modifications,
clarifications, suggestions, ideas, new questions, new answers to
questions which have never been asked, or something else that I have
not covered above, contact me at lvirden@cas.org.
------------------------------
From: FAQ General information
Subject: -II- What is Tcl? Tk? Extended Tcl?
o Highlights of Tcl based languages
Tcl and Tk originated with Dr. John Ousterhout (Oh'-stir-hout -
last syllable rhymes with rout, not root) from the University of California,
Berkeley, California.
Tcl (current release version 7.3) stands for ``tool command
language'' and is pronounced ``tickle.'' The author's home ftp site for
the Tcl source code is <URL:ftp://ftp.cs.berkeley.edu/ucb/tcl/>.
Tcl is actually two things: a language and a library. First, Tcl is a
simple textual language, intended primarily for issuing commands to
interactive programs such as text editors, debuggers, illustrators, and
shells. It has a simple syntax and is also programmable, so Tcl users
can write command procedures to provide more powerful commands than
those in the built-in set.
Second, Tcl is a library package that can be embedded in
application programs. The Tcl library consists of a parser for the Tcl
language, routines to implement the Tcl built-in commands, and
procedures that allow each application to extend Tcl with additional
commands specific to that application. The application program
generates Tcl commands and passes them to the Tcl parser for
execution. Commands may be generated by reading characters from an
input source, or by associating command strings with elements of the
application's user interface, such as menu entries, buttons, or
keystrokes. When the Tcl library receives commands it parses them into
component fields and executes built-in commands directly. For commands
implemented by the application, Tcl calls back to the application to
execute the commands. In many cases commands will invoke recursive
invocations of the Tcl interpreter by passing in additional strings to
execute (procedures, looping commands, and conditional commands all
work in this way).
An application program gains three advantages by using Tcl for
its command language. First, Tcl provides a standard syntax: once
users know Tcl, they will be able to issue commands easily to any
Tcl-based application. Second, Tcl provides programmability. All a
Tcl application needs to do is to implement a few application-specific
low-level commands. Tcl provides many utility commands plus a general
programming interface for building up complex command procedures. By
using Tcl, applications need not re-implement these features. Third,
extensions to Tcl, such as the Tk toolkit, provide mechanisms for
communicating between applications by sending Tcl commands back and
forth. The common Tcl language framework makes it easier for
applications to communicate with one another.
Note that Tcl was designed with the philosophy that one should
actually use two or more languages when designing large software
systems. One for manipulating complex internal data structures, or
where performance is key, and another, such as Tcl, for writting
smallish scripts that tie together the C pieces and provide hooks for
others to extend. For the Tcl scripts, ease of learning, ease of
programming and ease of glue-ing are more important than performance or
facilities for complex data structures and algorithms. Tcl was
designed to make it easy to drop into a lower language when you come
across tasks that make more sense at a lower level. In this way,
the basic core functionality can remain small and one need only bring
along pieces that one particular wants or needs.
Tk (current release 3.6) is an extension to Tcl which provides
the programmer with an interface to the X11 windowing system. Note
that Tk has been successfully compiled under X11 R4, X11 R5, X11 R6,
as well as Sun's NeWS/X11 environments.
The author's home ftp site for the Tk source is the directory
<URL:ftp://ftp.cs.berkeley.edu/ucb/tcl/>.
Note that many users will encounter Tk via the ``wish'' command. Wish
is a simple windowing shell which permits the user to write Tcl
applications in a prototyping environment. Tk 4.0 is in the works.
It is expected to appear by first quarter 95. Some of the changes to
expect are:
- A major overhaul of text widgets (embedded windows, horizontal
scrolling, better vertical scrolling, more display options such as
vertical spacing, margins, justification, and baseline offsets).
- An overhaul of bindings, including the binding tags discussed at
last year's workshop and a change in the evaluation mechanism to make
bindings more composable.
- A few other changes to event handling, including a new "fileevent"
command (similar to Mark Diekhans' "addinput") and the ability to
cancel "after" handlers.
- A general-purpose and user-extensible mechanism for images, intended to
handle things like color icons, full-color images, and video.
- Improvements to colormap and visual handling.
- A solution to the X resource id wrap-around problem that tends to cause
errors in long-running applications.
- A bunch of improvements to widgets, including justification in entries and
the ability to have multi-line text in widgets like buttons and labels.
Other things which may appear are:
- support for Motif keyboard traversal highlight rings and
completely overhaul the widget bindings to bring them into better Motif
compliance. Emacs-like bindings will also be provided for entries and
texts where they don't conflict with Motif bindings.
- Application embedding (like Sven Delmas' "tksteal" stuff, I think).
- Overhauls of the send command, the selection, and the input focus
mechanism.
Early beta release of Tk 4.0 is expected before fourth quarter 1994.
The future of Tcl and Tk is quite bright. This year Dr. Ousterhout
announced that he has been employed by Sun Microcomputer, Inc. to do
some further development of Tcl / Tk. Some of the short term (within the
next 12 months or so) plans that Dr. O has mentioned are:
- Ports of Tcl and Tk to both the PC and Mac, so scripts written on one
platform will run on any of the others, presenting their UI in the look
and feel of the platform on which they run.
- A commercial-quality graphical interface designer like Visual Basic or
NextStep.
- Dynamic loading of C code in Tcl.
- Incorporating Nathaniel Borenstein's Safe-Tcl back into the Tcl core,
so that there is a safe mechanism for executing untrusted scripts that
arrive via the Internet.
John has given me permission to add this quote as well:
From: ouster@tcl.eng.sun.com (John Ousterhout)
Newsgroups: comp.lang.tcl
Subject: Re: The future of TcL/Tk's Copyright Terms
Date: 31 Aug 1994 20:08:19 GMT
Organization: Sun Microsystems, Inc.
Message-ID: <342nvj$6e9@engnews2.Eng.Sun.COM>
> I discussed the status of the Tcl and Tk libraries with people at Sun
> as part of my pre-hire negotiations, and we're in agreement that they
> will remain free and unrestricted just as they have always been. Future
> enhancements made to Tcl and Tk by my group at Sun, including the ports
> to Macs and PCs, will be made freely available to anyone to use for
> any purpose. My view, and that of the people I report to at Sun, is
> that it wouldn't work for Sun to try to take Tcl and Tk proprietary
> anyway: someone (probably me, in a new job) would just pick up the
> last free release and start an independent development path. This
> would be a terrible thing for everyone since it would result in
> incompatible versions.
> Of course, Sun does need to make money from the work of my team or else
> they won't be able to continue to support us. Our current plan is to
> charge for development tools and interesting extensions and applications.
> Balancing the public and the profitable will be an ongoing challenge for
> us, but it is very important both to me and to Sun to keep the support
> of the existing Tcl community. I imagine this discussion will repeat
> from time to time over the next few years, but I think we can make things
> work out well for everyone.
Extended Tcl (tclX) (Version 7.3b) - This is an extended set of
commands for Tcl developed by Karl Lehenbauer and Mark Diekhans. The
authors' home ftp site for Extended Tcl is ftp.neosoft.com. Extended
Tcl is oriented towards system programming tasks, with many additional
interfaces to the Unix operating system along with other useful
utilities.
Rush is a Tcl-like extension language announced at the Tcl'94
Workshop. Its syntax and semantics are very similar to Tcl's, but it
additionally offers an optimizing compiler and a new feature called rules.
Its primary advantage over Tcl is performance within a factor of 100 of C,
whereas a Tcl compiler is unlikely to do better than a factor of 1000 of
C. Rush is not yet publicly available, though ambitious alpha testers
are encouraged to inquire. Mail can be sent to either asah@cs.berkeley.edu
or blojo@cs.berkeley.edu. For more information, see the paper
<URL:ftp://ginsberg.cs.berkeley.edu/pub/asah/papers/rush-tcl94.ps.gz>.
o General information about Tcl and Tk by glv@utdallas.edu (Glenn Vanderburg)
Tcl (Tool command language) is a freely distributable simple,
interpreted language designed to be used as a common extension and
customization language for applications. It was designed and
implemented by Dr. John Ousterhout in the hope that application
designers could spend more of their time on applications and less on
scripting languages, and in the hope that users could spend less time
learning new scripting languages for each new application. Many useful
applications, some of them sold commercially, use Tcl as their
scripting language.
Tcl is clean and regular, and relatively easy for non-hackers to
learn. It is command-oriented, and commands added by applications and
users exist on an equal footing with the built-in Tcl commands. Tcl
has both simple variables and associative arrays (tables), and all
values (including procedure bodies) are represented as strings.
Simple customization scripts (such as preference initialization
scripts) usually look much like novice users expect them to: a series
of simple commands which set options.
Tcl is implemented as a C library, which can be embedded in an
application. The application can add its own commands to the
interpreter (using a clean C interface). It is distributed under a
license which allows use for any purpose with no royalties.
The Tk toolkit is a Tcl extension (a group of new Tcl commands) which
provides a Tcl interface to the X Window System. Tk is one of the
easiest ways to build a graphical interface to an application, and due
to the interpreted nature of Tcl, Tk-based interfaces tend to be much
more customizable and dynamic than those built with one of the C- or
C++-based toolkits. Tk implements the Motif look and feel. A number
of interesting X applications are implemented entirely in Tk, with no
new application-specific commands at all. Tk also provides a
mechanism by which one application can send Tcl scripts to other
Tk-based applications running on the same display, for easy
cooperation between tools.
Tcl and Tk are mature, and quite stable, but they are not static:
Dr. Ousterhout has moved from Berkeley to Sun Microsystems, where his
group is pursuing such projects as a commercial-quality Tk
graphical interface designer, an on-the-fly Tcl compiler, and
Macintosh and Microsoft Windows ports of Tk. He has said that the
copyright status and licensing provisions of Tcl and Tk will not change.
As to what is Tcl not - in the context of the discussion in
comp.lang.tcl, it is not related directly to the Think C Library (TCL)
available on the Mac. Confusingly enough, the language concerned with
here _is_ available on the Mac, and someone in fact may have used Think C
to compile it there. Just one of those universal 'coincidences' that
set the stage for Vogon interstellar highway construction crews.
------------------------------
From: FAQ General information
Subject: -III- Do these packages run on my machine?
A. Unix
Tcl runs on Sun 3s and 4s running SunOS 4 and SunOS 5 (Solaris
1.x and 2.x), DECstations running Ultrix, DEC VAXen running Ultrix or
BSD, DEC Alphas running OSF/1, 386s running SCO Unix, Xenix, Bell-Tech,
Silicon Graphics running IRIX, HPs running HP-UX as well as HP Snakes
running OSF/1 and HP-UX. Intel [34]86 systems running
386bsd, netbsd, freebsd, BSDI, and Linux have Tcl ported. Various CPUs
running System V.4 report having ported Tcl. Tcl also appears to be
running on Sequent Symmetry running Dynix as well as OSF/1. It also
has been reported to run fine on IBM RS6000 under AIX 3.x as well as
IBM ES/9000 and AIX/ESA. There were few problems getting it running
under Mt. Xinu Mach. It also has been ported to Encore 91's running
UMAX V (an 88k based System V with BSD extension Unix). It also runs
on Apollos running BSD/SYSV. Tcl runs on a Cray running Unicos. Folks
have ported Tcl to a Mac (IIfx) running A/UX v3. Someone ported Tcl to
a Sony NeWS machine running NEWS-OS 4.2. A port to a Convex 3220 and
3880 was also reported.
Tk (being based on Tcl) generally requires X11R4 or better as
the only additional software requirement. It runs on any of the above
Unix systems with that base of software. It also runs on VMS and
OSF/1.
For information on Tcl/Tk/TclX availability (see "tcl-faq/part4").
B. MacOS
(See "tcl-faq/part2") for details of a Macintosh Tcl Mailing list.
Ray Johnson <rjohnson@aic.lockheed.com> has a package called
MacTcl. This is a fairly straight port of Tcl to the Macintosh. It is
designed to be used as libraries to be embedded into other
applications. A basic shell is included. Most Tcl features are
present, including many Unix-like features. Additional features
include supporting the env variable and sourcing Tcl code from a
resource. The current version is available at
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/distrib/MacTcl7.3.sea.hqx>.
As of this time, I have no leads on anyone porting Tk to MacOS.
I also have not heard of anyone porting Tcl/Tk to a Apple PowerMac.
Also (see "tcl-faq/part4"), the Tcl programs/packages catalog,
for the latest port locations and versions.
C. INTEL DOS-like systems
Numerous ports to DOS are available. One unsupported port to
MS-DOS of Tcl and Extended Tcl V6.0a, done by
Karl@NeoSoft.com (Karl Lehenbauer), is available on
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/distrib/dostcl.zoo> for binaries and
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/distrib/dostcl60.zoo> for source.
A port of Tcl V6.2 to MS-DOS was done by
johnm@cajal.uoregon.edu (John Martin) and is available via FTP from
<URL:ftp://cajal.uoregon.edu/pub/tcl.dos.port/> and
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/distrib/tcl62.dos.tar.Z>.
A source code only port of Tcl V6.7 to MS-DOS, done by
PSPRENG@CIPVAX.BIOLAN.UNI-KOELN.DE (Peter Sprenger), is available from
him, somewhere on wuarchive.wustl.edu
or as
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/distrib/tcl67dos.zip>.
A port of Tcl, version 7.3, to MS-DOS, done by
tpoind@advtech.uswest.com (Tom Poindexter), is available as
<URL:ftp://harbor.ecn.purdue/edu/pub/tcl/distrib/mstcl73*.zip>. This
also includes TclX 7.3a and Tk ported to Desqview/X libraries.
A port of Tcl, V6.1 ?, done by unknown, to MS-DOS Windows
V 3.1 ?, is available as binary at
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/distrib/w_tclbin.zip> and as source at
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/distrib/w_tclsrc.zip>.
A package to take a Tcl source distribution and port it cleanly
to MS-DOS, so that it can be compiled has been written by
Bob Yennaco (byennaco@east.sun.com). It is available as
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/distrib/tcl2dos.sh.gz>
An MS-DOS Windows DLL instance of Tcl 6.2 was generated by
Ugo Cei <ugo@oliver.sublink.org>. Contact him for more details.
A Windows DLL was made by ekki@prakinf.tu-ilmenau.de (Ekkehard Beier)
by slightly modifying a DOS 6.2 Tcl port. There are still problems
with the system/WinExec command. A very rudimentary Debugger User Interface
using Borland's Classlib is part of the zip-file, too.
The source was used also with BC3.1++/AF on MS W3.1. You can get a copy from
<URL:ftp://metallica.prakinf.tu-ilmenau.de/pub/DOS/wintcl.zip>
via anonymous ftp. Unfortunately Ekki doesn't have time currently to
finish the Windows port and user Interface.
haga@sra.co.jp (Toshihiko Haga) and miyata@sra.co.jp (Shigeaki Miyata)
announced twin (tcl/tk for MS-Windows), which does not support exec and
send, but supports a -bitmap for Windows .bmp files. A few other
modifications or special exceptions are noted. This package's files
can be found at
<URL:ftp://ftp.sra.co.jp/pub/lang/tcl/{twinesrc,twinebin}.zip> and
<URL:ftp://ftp.sra.co.jp/pub/lang/tcl/{twinesrc,twinebin}.doc>.
Professor Ken K. Kubota <ken@ms.uky.edu> has announced a port
of Tcl 7.3 and Tk3.6a to MS DOS Windows using Borland C++ 4.0. Fetch
the README files from the ftp sites
<URL:ftp://ftp.ms.uky.edu/pub/tk-win/{tkwinbin,tkwin,fedloc}.zip>
for more information.
Omar Stanford <omar@fcm.missouri.edu> reported in March of 1994
that he had almost completed his port of Tcl 7.3 to MS-Windows 3.1.
He had incorporated extensions for networking (including NetWare),
Windows Sockets, and many Windows API functions. He also was working on
a facility for dynamically allocating commands to the Tcl environment.
If there are other extensions that one would like to see under Windows 3.1,
or if you are interested in beta testing, drop him a line.
Also, Simon Kenyon <simon@news.itc.icl.ie> of the Information
Technology Centre, Dublin, IRELAND, mentions that they are starting to
port Tk to MS-Windows. There is a mailing list (see below) for
folk who are interested.
Steve Furr <furr@qnx.com> reports getting Tcl ported to QNX
without a lot of trouble. He mentions that QNX users who have the
beta X should have gotten a CD-ROM update with Tcl and Tk on the CD.
A port of Tcl 7.3, except for glob or command pipelines, to OS/2 2.x
using C Set++ has been done by wwb@wwa.com (Bud Bach). As of this date, I
have no leads on anyone porting Tk to any version of OS/2. There is some
OS/2 X client support kits available for purchase, which might make it
easier to port Tk.
Also (see "tcl-faq/part4"), the Tcl programs/packages catalog,
for the latest port locations.
D. VMS
A port of Tcl 7.3 and Tk 3.6 to VMS was done by Angel Li
<angel@flipper.rsmas.miami.edu>. The files are at
<URL:ftp://mango.rsmas.miami.edu/pub/VMS-tcl/tcl73-tk36-itcl13.tar.Z>
and were compressed with the Unix compress command. The pathname may
be subject to change as I have seen notes from Angel Li mentioning that
BLT 1.6 and the photo widget have also been ported. These were compiled
on an Alpha running OpenVMS T6.1.
A port of Tcl 6.3 onto VMS 5.5 was done by Wolfgang Kechel
<wolfgang@pr-wiesbaden.de> and Till Imanuel Panzschke. Contact them
directly for assistance.
A port of most of Tcl 6.7 and Tk 3.2 was done by John Kimball
<jkimball@src.honeywell.com> to VMS 5.5. The files are on
<URL:ftp://src.honeywell.com/pub/tcl67-tk32-on-vms55.tar.Z>.
A port of Tcl 7.0 and Tk 3.3 has being done to VMS on the
VAX and Alpha. These are available as:
<URL:ftp://src.honeywell.com/pub/vms-tcl/tcl70-tk33-on-vms55.tar.Z>
or
<URL:ftp://src.honeywell.com/pub/tcl70-tk33-on-vms55.tar.Z>.
Gerald W. Lester (gwlester@cpu.com) says the following _should_ work.
If you installed the POSIX package on VMS (its free), then you should be
able to configure and make tcl. To access tcl you would have to do one
of the following: 1) Use the POSIX shell, or 2) do a "psx tcl".
Tcl scripts would not execute directly from DCL; to execute a script foo.tcl
from DCL you would have to do "psx foo.tcl".
DISCLAIMER: I have not built any version of tcl under VMS POSIX, these
comments are based on other work I've done with VMS POSIX.
Also (see "tcl-faq/part4"), the Tcl programs/packages catalog,
for the latest port locations.
E. AmigaDOS
Karl Lehbauer <karl@sugar.NeoSoft.com> has indicated that
he started a port of Tcl 3.x to the Amiga. He has a working
version, but is no longer working on it. His version uses the
Amiga's shared libraries and implements the "send" command.
He wrote a MIDI file loader and player as well. Contact him for
further details.
Ty Sarna <tsarna@endicor.com> has ported Tcl 6.x to the Amiga.
He says:
> I've ported 3.3 and several 6.x versions to the Amiga, and it can be
> done in under and hour if you leave out the "Unix" functionality.
> However, "Unix" functionality includes things like file I/O!
Another Amiga user, colas@opossum.inria.fr (Colas Nahaboo), mentioned
that using Amiga gcc and the PD X server DaggeX and Xlibs that a port of
Tk might be possible.
hnm@hermes.bouw.tno.nl (Marco van der Heiden) has completed a port
to the Amiga, and suggests Amiga developers contact him by email.
Also (see "tcl-faq/part4"), the Tcl programs/packages catalog,
for the latest port locations.
F. NeXT
Gianmaria Bertanzon <gm@itnsun4.lii.unitn.it> reports:
We are using tk3.2 on NeXT ( Motorola ) under NextStep 3.0 under X.
The compilation was easy. (we do not remember precisely all the steps)
Also (see "tcl-faq/part4"), the Tcl programs/packages catalog,
for the latest port locations.
G. Other
A port to the Apple IIgs and GNO 1.1/GSOS environment is underway.
A beta port of Tcl 7 has been done to VxWorks.
You can find it at
<URL:ftp://thor.atd.ucar.edu/pub/vx/tclvx7.0.v2.tar.gz>
or a name similar (if updates have occurred).
Also (see "tcl-faq/part4"), the Tcl programs/packages catalog,
for the latest port locations.
------------------------------
From: FAQ General information
Subject: -IV- Other than C, what languages can talk to tcl/tk?
A. Shell
There are at least two interfaces which are shell-like. The
first is wish, which is a windowing shell like interface that is a part
of the Tk package. The second is tcl, a line command interpreter that
is part of the Extended Tcl package.
B. C++
There is a package called Objectify which can be used to assist
one in turning C++ classes into Tcl object types.
If you wish to use C++ with Tcl then you must have your main()
in a source file that is compiled with a C++ compiler; this will
ensure that the necessary C++ pre-main initialization code is
executed.
You can call tcl and tk routines (or other C code) routines from C++
provided that the function prototypes avoid C++ name mangling by using
the C++ linkage specification :
extern "C" ... prototype ...
Fortunately, tcl.h and tk.h will provide these specifications when
compiled with a C++ compiler and so you can just use them directly.
You can construct your main using normal tcl and tk routines, or
use tkMain.c and tkAppInit.c with minor modifications. Ken Yap's
patches obtainable from ...
<URL:ftp://harbor.ecn.purdue.edu/pub/tcl/distrib/tk3.2forC++.patch>
is a patch that allows tk 3.2 main.c and other extension routines
to be compiled with a C++ compiler. Thanks to Ken Yap <ken@syd.dit.csiro.au>
for this code.
C++ functions and static class member functions can be used to
create Tcl command using Tcl_CreateCommand in the normal way.
Non-static member functions cannot be used so simply, Tcl would
have to supply a "this" pointer.
Check out tcl++.h in Extended Tcl. Based on an original
implementation by Parag Patel, it defines a Tcl interpreter class by
which Tcl interpreters can be created as objects under C++.
Mark Diekhans and Karl Lehenbauer have used this, in
combination with the handle facility in Extended Tcl, to build Tcl
commands around C++ classes.
The Tcl handle facility provides a way to manage table entries
that can be referenced by a textual handle from Tcl code. This is
provided for applications that need to create data structures in one
command, return a reference (i.e. pointer) to that particular data
structure and then access that data structure in other commands. An
example application is file handles.
A handle table was built containing pointers to the instances
of a class that were to be accessed from Tcl, say a class `foo_cl', and
then a "new" command defined that created an instance of that class and
returned a Tcl handle to it. The handle could then passed among Tcl
commands that accessed each member function. The handle is in effect
an explicit `this' pointer.
For example:
set obj [foo_cl::new]
foo_cl::baz $obj "Hello world"
foo_cl::delete $obj
It's not totally object-oriented, but it's still very usable.
C. Modula-3
Norman Ramsey <elan.uucp!nr> says:
A long time back, Eric Muller posted a Modula-3 interface to
the C Tcl library. I wrote down a Modula-3/Tcl interface that used
Modula-3 types rather than C types, and that used objects to build
closures for commands. I wrote part of the implementation but never
finished it. I have mailed copies to carroll@udel.edu, who asked the
question, and I will post them if there seems to be general interest.
Also, there is an interface between Tk and Modula-3 that is a part
of the Modula-3 archives on gatekeeper.dec.com, and Tcl-DP and
Modula-3 have been merged.
D. Eiffel
stephan@cs.tu-berlin.de (Stephan Herrmann) says:
... [the tclish package provides] the marriage of two very different
principles by means of combining two programming languages into a
hybrid program architecture.
There are three classes for the user - tcl interpretor, tk application,
and tk window. See <URL:ftp://hepunx.rl.ac.uk/pub/eiffel/tclish> for
details.
E. Ada
dennis@dennis.cs.colorado.edu (Dennis Heimbigner) introduced
an adatcl package which gives Ada programmers access to Tcl interpreters.
See the catalog for details of the package.
F. Perl
Two different projects are underway - see comp.lang.perl
for discussions on adding a Tk like interface to Perl version 4 as well
as Perl version 5. This is more an interface based on Tk ideas
than to actual Tcl code from what I understand.
G. Prolog
The package ProTcl is an interface between Prolog and Tcl/Tk.
It works best with ECLiPSe, but the foreign interface of SICStus and Quintus
is also provided. The interface is dynamically loaded into a Prolog process
and it gives access to Tcl commands and to handling Tk events. It is also
possible to call Prolog from Tcl, handle Tk events in Prolog and to
pass Prolog variables back to Tcl. See
<URL:http://www.ecrc.de/eclipse/html/protcl.html> for more details.
H. Other
Work at consolidating Python and Tk is underway - discussion
is proceeding in comp.lang.python on this front as the code is primarily
Python.
Some work relating to the Fresco CORBA interpreter has resulted in a
Tcl-based interpreter which interacts with that environment.
Some work on Tk bindings for the Dylan language are being investigated
as well as Tk bindings for Sather.
Duncan Sinclair <sinclair@dcs.gla.ac.uk> has details of a hack
into wish.c some hooks for a Tk <-> any language system, and has been using
it for communication with functional languages such as Haskell and Lazy ML.
A paper, plus sample code, is available by ftp from
<URL:ftp://ftp.dcs.gla.ac.uk/pub/glasgow-fp/authors/Duncan_Sinclair/fumx.*>.
The InterLanguage Unification project is a system that promotes
software interoperability via interfaces. It has the ability to allow
Common Lisp, ANSI C, C++, Modula 3 to interact and plans to add Python,
Tcl, and GNU Emacs-Lisp shortly.
Of course the Wafe application environment is designed to make
it easier to do X like applications from within several languages using
Tk as a basis.
There are several interfaces to allow one to interface with SQL
though some are specific to a database such as Oracle.
There is an interpretor for Silicon Graphics machines for SGI's
GL language.
There is an interface to WOOL.
For more details on the above efforts, (see also "tcl-faq/part04").
------------------------------
From: FAQ General information
Subject: -V- What training material is available?
A. Training courses, materials, etc.
1. A text book by John K. Ousterhout is available from Addison Wesley.
It's title is _Tcl and the Tk Toolkit_ and has an ISBN of 0-201-63337-X.
The first printing was in April of 1994. I believe that the third printing
is now available. The book primarily covers Tcl 7.3 and Tk 3.6.
2. A physical copy of the Tcl / Tk distributed documentation is
available at the Northside Copy Central in Berkeley under the name "TCL" and
is titled "Tcl/Tk Documents". Northside Copy Central is at 1862 Euclid
with a phone of (510) 849-9600. It costs approx. $15-$20 for the book in
a spiral bound, pink cover, clear plastic front and back format.
3. A tutorial by Don Libes is in the works. Here is a blurb from the author
himself:
Title: Exploring Expect
Subtitle: A Tcl-Based Toolkit for Automating Interactive Applications
Publisher: O'Reilly and Associates, Inc
ISBN: 1-56592-089-9
Pages: 575
Expected Date: October-November '94
For all of you who thought that the Expect man page was too long and too
terse at the same time, this book provides relief. "Exploring Expect"
is an introduction and comprehensive tutorial to Expect. Numerous
examples are provided and explained, demonstrating how to save you time
and money. Example topics include how to write patterns, do signal
handling, use Expect as a telnetable daemon, and use Expect with Tk and
other Tcl extensions.
The book also includes an innovative introduction to Tcl - if you've
had trouble using Tcl before, all of a sudden, it will make a lot more
sense. And while Exploring Expect concentrates primarily on using
Expect with Tcl, programmers attempting to automate interactive
programs using C, Perl, Python, or any other language will find this
book helpful because many of the concepts underlying Expect-like
programming are common to all languages.
4. Additional books specifically dealing with Tcl are in the process of
being written. For instance, by Brent Welch, _Practical Programming in
TCL and TK_ to be published by Prentice Hall. See the Tcl bibliography
for details of other references.
5. Computerized Processes Unlimited has a combined Tcl/Tclx reference
manual for sale. They also offer courses on Tcl.
(See also "tcl-commercial-faq") for more information.
6. NeoSoft Communications Services teaches introductory and advanced
Tcl courses on site or at their location in Houston, Texas.
(See also "tcl-commercial-faq") for more information.
See the Tcl bibliography for more books, magazine and journal articles ,
proceedings papers, and thesises relating to the Tcl family of languages.
B. Time-related seminars, conferences, sessions.
1. There have been, in the past, seminars at Usenix and an MIT X
conference taught by John Ousterhout (and sometimes by others) on Tcl and Tk.
(See also "tcl-faq/part02") for the URL to the slides from the most recent
of these presentations.
2. An upcoming USENIX symposium will be dealing with Perl, Tcl and other
similar languages. Here is the information I have to date.
Symposium on Very High Level Languages
October 26-28, 1994
El Dorado Hotel
Santa Fe, New Mexico
Program Chair: Tom Christiansen (tchrist@usenix.org)
Extended abstracts due June 30, 1994
3. University of Maryland Baltimore County is offering
CMSC491C - Special Topics in Computer Science - Scripting Languages.
This is an intro to scripting languages with an emphasis on Perl and
Tcl, but also mentioning sed, awk, etc. Taught by Bob Tarr, Tuesdays
and Thursdays from 5:30-6:45pm. Call (410) 455-2336 (Continuing
Education Department) to sign up as a special non-degree candidate.
Info provided by finin@cs.umbc.edu (Tim Finin).
4. The UC Berkeley Extension program is offering a 10 week course on
"Developing User Interfaces with X Windows and C++"taught by
Sriram Srinivasan. This course is being conducted on the
UC Berkeley (Berkeley, CA, USA) campus from Sep 15 thru Nov 17, every
Thursday, from 7-10 p.m. It includes Tcl, Fresco, ET++, as well as
many other UI development choices. For course details, please contact
Mark Palermo
Continuing Education in Engg.
(510)642-4151, course@garnet.berkeley.edu
Course EDP number: EDP 308684
Course Fees : $335
------------------------------
From: FAQ General information
Subject: -VI- Where do I report problems, bugs, or enhancements - or -
What is comp.lang.tcl?
There are two alternatives for reporting bugs and problems.
The first is the USENET news group <URL:news:comp.lang.tcl>, an unmoderated
USENET newsgroup, created for the discussion of the Tcl programming language
and tools that use some form of Tcl, such as: the Tk toolkit for the X window
system, Extended Tcl, and expect. Please note that postings of source
code to comp.lang.tcl does not automatically get archived on
harbor.ecn.purdue.edu - if you want your code to be available from the
User Contributions archive you will need to make arrangements with the
folks there to have it added. See elsewhere in the FAQ for more details on
the harbor archive site.
The second would be to report problems, suggestions, new
ideas, etc. directly to the author. Email to
John.Ousterhout@eng.sun.com (John Ousterhout)
will reach the author of Tcl and Tk - to find the email
address of the authors of other Tcl/Tk based programs,
(see "tcl-faq/part4"), and (see "tcl-faq/part5").
One question that comes up fairly often concerning comp.lang.tcl
is why it isn't split. The newsgroup varies in traffic, but recently
I have seen it as much as 45 messages a day (counting current cross
postings, etc.) Dr. Ousterhout was the created of the unmoderated
comp.lang.tcl. Currently, no one has come forward with the time and
resources to run a discussion of how a split could be handled, nor
have any moderators stepped forward to take over moderation of a group
such as comp.lang.tcl.announce for instance. So to date, such a question
is good for adding to the existing traffic, but that is about all the
farther things go.
------------------------------
End of comp.lang.tcl Frequently Asked Questions (1/5)
*****************************************************
--
:s Great net resources sought...
:s Larry W. Virden INET: lvirden@cas.org
:s <URL:http://www.mps.ohio-state.edu/cgi-bin/hpp?lvirden_sig.html>
The task of an educator should be to irrigate the desert not clear the forest.
--
:s Great net resources sought...
:s Larry W. Virden INET: lvirden@cas.org
:s <URL:http://www.mps.ohio-state.edu/cgi-bin/hpp?lvirden_sig.html>
The task of an educator should be to irrigate the desert not clear the forest.