[REBOL] Re: How to refresh a text-list
From: gscottjones:mchsi at: 26-Feb-2002 5:33
> From: "Ashley"
>> Doubtless this has been asked before (no luck after a quick EScribe
>> search), but how does one refresh a text-list.
...
From: "Cyphre"
...
> view layout [
> a: area form read %. 'wrap
> button "Area" [a/text: read %.. show a]
> b: text-list data read %.
> button "List" [b/lines: read %.. show b]
> ]
>
> Using 'lines instead 'data variable looks like little inconsistecy in the
> 'text-list style ;-)
...
Hi, Ashley,
Then, to "fix" the slider. you need to add a handy-dandy function, like
this:
fix-slider: func [faces [object! block!]] [
foreach list to-block faces [
list/sld/redrag list/lc / max 1 length? head list/lines
]
]
view layout [
a: area form read %. 'wrap
button "Area" [a/text: read %.. show a]
b: text-list data read %.
button "List" [
b/lines: read %..
fix-slider b
show b
]
]
--Scott Jones