[ALLY] text-list scrolling from program?
[1/4] from: ingo:2b1 at: 3-Nov-2000 1:14
Hi Allies, if I set the /picked line in a text-list programmatically, this may be scrolled out of the display, how can I let the text-list scroll to show the picked line? best regards, Ingo
[2/4] from: agem:crosswinds at: 4-Nov-2000 11:48
[ingo--2b1--de] wrote on 3-Nov-2000/1:14:40+1:00
> Hi Allies, > > if I set the /picked line in a text-list programmatically, > this may be scrolled out of the display, how can I let the > text-list scroll to show the picked line? >
hacked a bit around. calculate yourself :) [rebol view/new layout[ tl: text-list data insert/dup ["hello" "ween"] "loeloeloe" 15 button "test"[ tl/sld/data: 0.99 tl/sld/action tl/sld 0.99 tl/picked: "hello" show tl] ] ] a: get-style 'text-list probe a/facets ;probe a/sld/facets do-events
> best regards, > > Ingo >
may the source be with you :) Volker
[3/4] from: carl:cybercraft at: 4-Nov-2000 16:18
Hi Ingo, On 03-Nov-00, Ingo Hohmann wrote:
> Hi Allies, > if I set the /picked line in a text-list programmatically, > this may be scrolled out of the display, how can I let the > text-list scroll to show the picked line?
I've been playing with lists and know how to scroll them and point them at any line you want, (see the script below, specifically the First and Fifth buttons), but I don't know how to show a picked item! (Well, not properly, anway.) So, how do you do it? (: Carl Read. rebol [ Title: "List Example" ] list-block: ["aaa" "bbb" "ccc" "ddd" "eee" "fff" "ggg"] list-window: view layout [ the-list: list 206x64 180.180.180 [text 206x15 ] data list-block map [text] supply [ face/text: pick list-block count face/data: count ] across button "up" [ list-block: back list-block show the-list ] button "down" [ list-block: next list-block show the-list ] return button "first" [ list-block: head list-block show the-list ] button "fifth" [ list-block: skip head list-block 4 show the-list ] ] do list-window
[4/4] from: ingo::2b1::de at: 6-Nov-2000 11:12
Thanks Carl, and here's my contrib: view layout [ l: text-list "a" "b" "c" "d" "e" button "pick3" [ clear l/picked append l/picked pick l/data 3 show l ] ] kind regards, Ingo Once upon a time Carl Read spoketh thus: