swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Q] Difference between TkInterp and wish8.0


From: Pietro Terna
Subject: Re: [Q] Difference between TkInterp and wish8.0
Date: Sat, 17 Jul 1999 16:19:09 +0200

        Hi Gary,

        this is not a direct hlep, but at
ftp://ftp.santafe.edu/pub/swarm/users-contrib/anarchy/tclTest-1.3.tar.gz
you can find an application of mine using tcl in Swarm.

        Pietro

At 11.50 17/07/99 +0100, you wrote:
>
>I've been trying to do some Tcl/Tk from inside Swarm, without much success.
>As a Tcl/Tk newbie this is probably not much of a surprise. My Tcl/Tk book
>mentions the tk_getOpenFile megawidget -- available from Tk8.0, and if I
>run wish8.0 from my tk installation directory, I can do:
>
>tk_getOpenFile -filetypes {{{LandParcel Files} {.lp}}}
>
>and up pops a very nice file-opening dialogue box for opening a datafile
>for my Swarm application (a simulation of rural land use decision-making).
>(My plan was to attach this to a button from a ButtonPanel object or
something.)
>
>Inside ObserverSwarm, I have a method that calls:
>
>  [globalTkInterp eval:
>                   "tk_getOpenFile -filetypes {{{LandParcel Files} {.lp}}}"];
>
>and when it gets there, I get the following error message:
>
>(Tcl -eval:) no value given for parameter "specs" to "tclParseConfigSpec"
>    while executing
>"tclParseConfigSpec {__tk_filedialog {
>        {-defaultextension "" "" ""}
>        {-filetypes "" "" ""}
>        {-initialdir "" "" ""}
>    invoked from within
>"unknown_pre_tclObjc $name $args"
>    (procedure "unknown" line 6)
>    invoked from within
>"tclParseConfigSpec $w $specs "" $argList"
>    (procedure "tkFDialog_Config" line 27)
>    invoked from within
>"tkFDialog_Config $w $type $args"
>    (procedure "tk_getOpenFile" line 12)
>    invoked from within
>"tk_getOpenFile -filetypes {{{LandParcel Files} {.lp}}}"
>while evaluating: tk_getOpenFile -filetypes {{{LandParcel Files} {.lp}}}
>no value given for parameter "specs" to "tclParseConfigSpec"
>
>I have no idea what to do to get round this -- if anyone has any
>suggestions, I'd be very grateful.
>
>More generally, what is the difference between running something from
>TkInterp, and from wish8.0? What sort of Tcl/Tk commands can you run
>from TkInterp succesfully, and what not? What caveats are there to
>someone wanting to fiddle with the Swarm GUI? (E.g. I have a lot of
>ZoomRasters -- how difficult would it be to amalgamate them onto one
>window, that would select between the one displayed using a listbox
>or buttons? Could a similar thing be done for EZGraphs?)
>
>       Gary
>
>-- 
>
>Macaulay Land Use Research Institute, Craigiebuckler, Aberdeen. AB15 8QH
>Tel: +44 (0) 1224 318611               Email: address@hidden
>
>                  ==================================
>   Swarm-Support is for discussion of the technical details of the day
>   to day usage of Swarm.  For list administration needs (esp.
>   [un]subscribing), please send a message to <address@hidden>
>   with "help" in the body of the message.
>
>


                  ==================================
   Swarm-Support is for discussion of the technical details of the day
   to day usage of Swarm.  For list administration needs (esp.
   [un]subscribing), please send a message to <address@hidden>
   with "help" in the body of the message.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]