[REBOL] Re: Yet More VID Help...
From: volker:nitsch:g:mail at: 17-Apr-2006 11:17
On 4/16/06, Charles <chalz-earthlink.net> wrote:
> Yep, it's me again. I'm getting the increasing feeling I'm either over my
> head, or missing some very simplistic explanation...
> Something I'm working on with VID involves a "list" with two columns of
> data. Easy enough to set up. I create a bunch of styles outside of layout,
> one of which is
> >> out-list: list 254x512 [origin 0 across text 60 text 80]
> Then after loading the styles in the layout, I do:
> >> out-disp: out-list data [[0 "="] [1 "+"]]
> That's great. It works. The problem is, I can't figure out where the data
> is being stored, how to access it, manipulate it, add on to it, etc. I
> printed out the contents, and the only place I could find the data was in
> >> subfunc: func [face count index /item /stuff][
> stuff: [[0 "="] [1 "+"]]
> either count > length? stuff [face/text: "" face/image: none] [
> set-it face stuff index count
> So, I don't get it. With most other types, you can access <object>/text or
> <object>/data. What's going on here?
Magic. And the magician didn't bother about changing lists to much.
Use 'supply, like this:
stuff: copy 
view layout [
lst: list [across info info] 400x400 supply [
either count > length? stuff [face/text: "" face/image: none] [
lst/set-it face stuff index count
; with [probe words source set-it] ; get some hints
button "add now" [
append/only stuff reduce [mold 1 + length? stuff mold now/time]
> On a subnote, is there a doc elaborating on the pre-defined styles
> Again, my thanks to you all.
> To unsubscribe from the list, just send an email to
> lists at rebol.com with unsubscribe as the subject.
Any problem in computer science can be solved with another layer of
indirection. But that usually will create another problem.