Re: getting "what went in" from "what comes out" of listboxes

From: Erick Gallesio <eg_at_kaolin.unice.fr>
Date: Wed, 27 Jul 1994 11:43:43 +0100

>
> if i insert "foo bar" into a listbox and select it, it comes out as
> '(foo bar). i understand why but what's the real world work-around?
> can anyone suggest a simple change that will allow me to get "foo bar"
> back out? if not, what's the simplest method for converting "foo bar"
> to '(foo bar)?

This is a STk bug. The problem for fixing this bug is that code for detailers
relies on this "feature". In al the cases, I will try to fix it rapidly.

Hint: try to use the "selection" primitive which will return a string in all
the cases. I hope you can use it until the fix.


>
> as another "what's the right/best way" question - what's the best
> technique for popping up a dialog box and returning a value? should i
> wait on a variable or on a window? do i need to define a global
> variable that gets assigned a value? the only "reference" i found is
> the code in the Filebox/make-file-box and it seems a little messier
> than i'd expect. (it works though so i'm not complaining!)

Most of the time, grab can do the job. See the comment (I know, I know a doc
would be better...) in the file Lib/dialog.stk . You'll see that the dialog
box can wait until a button is pressed (:grab option of make-dialog).

>
> if anybody has some "good" stklos code i'd love to peruse it. reading
> other peoples code is a great way to pick up some pointers to using
> stklos effectively.

Yes. If someone has a good STklos demo, I would be happy to integrate it in
the distribution.


                -- Erick
Received on Wed Jul 27 1994 - 11:48:14 CEST

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