stk -geometry is broken

From: Harvey J. Stein <abel_at_netvision.net.il>
Date: Wed, 25 Sep 1996 12:12:57 +0200

Clifford Beshers writes:
>
> Has anyone noticed this?
>
> > stk -geometry +0+0
>
> *** Background error:
> unbound variable: *root*
> Current eval stack:
> __________________
> 0 *root*
> 1 (wm (quote geometry) *root* (quote +0+0))
> **** Warning:
> Welcome to the STk interpreter version 3.1 [HP-UX-9.X-9000s700]
> Copyright ) 1993-1996 Erick Gallesio - I3S - CNRS / ESSI <eg_at_unice.fr>
> STk>
>
> *root* is defined when things start up, but apparently the geometry
> request gets executed too soon.
>
> I haven't looked for the cause yet.

This bug has already been reported. You can fix/work around it by
editing tk-main.c. Here's the change as a diff -cw:

--- tk-main.c~ Tue Jul 23 17:45:23 1996
+++ tk-main.c Tue Sep 10 13:49:34 1996
_at_@ -165,7 +165,7 @@
 #endif
   /* Set the geometry of the main window, if requested. */
   if (geometry != NULL) {
- if (TCL_OK != Tcl_VarEval(STk_main_interp, "(wm 'geometry *root* '",
+ if (TCL_OK != Tcl_VarEval(STk_main_interp, "(wm 'geometry \".\" '",
                              geometry, ")", NULL))
       fprintf(STk_stderr, "**** Warning: %s\n", STk_main_interp->result);
   }

Good luck,

-- 
Dr. Harvey J. Stein
Berger Financial Research
abel_at_netvision.net.il
Received on Wed Sep 25 1996 - 12:22:22 CEST

This archive was generated by hypermail 2.3.0 : Mon Jul 21 2014 - 19:38:59 CEST