Hi Sterling

Nice example, but a couple of small probs. The button colors don't change
and the button is half off window after resize (maybe what was intended?).

Here's a quick mod which changes button color and keeps the button at the
bottom right corner.

-Larry

----------------modified script-------------------------

A quick resize example...

REBOL []

main-lay: layout [
b1: button red "Quit" [quit]
]

view/new/options main-lay [resize]

main-lay/feel: make main-lay/feel [
 detect: func [face event] [
  switch event/type [
   resize [
    b1/color: random 255.255.255
    b1/offset: main-lay/size - (b1/size)
    show b1
   ]
  ]
 event
 ]
]
wait none

-------------end mod--------------------

----- Original Message -----
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, May 07, 2001 4:24 PM
Subject: [REBOL] Re: window resize and window scroll


>
> A quick resize example...
>
> REBOL []
>
> main-lay: layout [
> b1: button "Quit" [quit]
> ]
>
> view/new/options main-lay [resize]
>
> main-lay/feel: make main-lay/feel [
> detect: func [face event] [
> switch event/type [
> resize [
> b1/color: random 255.255.255
> b1/offset: main-lay/size - (b1/size / 2)
> show b1
> ]
> ]
> event
> ]
> ]
>
> wait none
>
> Sterling
>
> > On Mon, 07 May 2001 23:41:57 +0200 (CEST)
> >  [EMAIL PROTECTED] wrote:
> >
> > > i want to have the ability to resize the window, which
> > > will opened with view
> > > and i want to use scroll bars too.
> > > Can anybody help me?
> >
> > For the latter check out the vid faq using vidwikibeta
> > at http://www.compkarori.co.nz/index.r :-)
> >
> > --
> > Graham Chiu
>
> --
> To unsubscribe from this list, please send an email to
> [EMAIL PROTECTED] with "unsubscribe" in the
> subject, without the quotes.

-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.

Reply via email to