X11, Tcl and Tk for Windows
Benjamin Riefenstahl
Benjamin.Riefenstahl@epost.de
Thu Sep 18 10:24:00 GMT 2003
Hi Mark,
Mark Horn <mark.horn@csiro.au> writes:
> I am looking for Tcl/Tk v8.0 and a compatible version of Xlib, for a
> port of an application developed originally for a Unix platform.
You may want to discuss Tcl/Tk issues on comp.lang.tcl. There are
much more people with specific Tcl/Tk knowledge there.
> _pint = Tcl_CreateInterp();
> Tcl_Init (_pint);
> _tk_mainwin = Tk_MainWindow (_pint);
> _pdisp= Tk_Display (_tk_mainwin);
> int idc = DefaultColormap (_pdisp, 0); // Failure here, or in
> subsequent call to XParseColor ()
> I have also tried linking with libraries tcl84.lib , tk84.lib from
> the Tcl/Tk distribution at http://www.tcl.tk/software/ includes.
> but in that case I get a failure in the call to Tcl_Init.
Which error? If Tcl_Init() returns an error, that can be a
configuration error in the Tcl/Tk installation or an error in the
calling sequence. I remember that it is important to call
Tcl_FindExecutable(), especially on Windows.
There have been significant changes in Tcl/Tk from 8.0 to 8.1 (most
importantly the switch to Unicode), so using a more recent version may
complicate matters. You may instead want to use the version 8.0.5
from http://sourceforge.net/project/showfiles.php?group_id=10894.
That page has source as well as native Windows Tcl versions.
The native Windows version of Tk has some X11 emulation built-in for
it's own use, so you may want to try to use that first. If that X11
emulation isn't enough for you, you can compile your own 8.0 Cygwin
Tcl/Tk and run that under Cygwin-XFree86, there is no reason that that
couldn't work.
benny
More information about the Cygwin-xfree
mailing list