[REBOL] Re: EVOScript
From: g:santilli:tiscalinet:it at: 26-Nov-2002 10:52
Hi Ronald,
On Tuesday, November 26, 2002, 10:50:23 AM, you wrote:
r> Why does this change of shape happen ?
Because you're overwriting the button effect:
>> b: get-style 'btn
>> print mold b/init
[
if size/x = -1 [
either text [
size/x: 1000
state: size-text self
size/x: either state [state/x + font/offset/x] [50]
state: none
] [
size/x: 50
]
]
if font/colors [font/color: first font/colors]
if not images [
images: reduce [btn-up.png btn-dn.png]
if not any [colors color] [color: 220.220.220]
]
if images [image: images/1]
if colors [color: colors/1]
if all [image not effect] [
effect: reduce ['extend image/size/2]
if color [append effect reduce ['colorize color]]
]
color: none
]
Look at the part:
if all [image not effect] [
effect: reduce ['extend image/size/2]
if color [append effect reduce ['colorize color]]
]
you already provided an effect, so it is no more adding the EXTEND
effect.
Try with:
Button "Pretty-print" effect [extend 22 multiply 255.150.0] [
Regards,
Gabriele.
--
Gabriele Santilli <[g--santilli--tiscalinet--it]> -- REBOL Programmer
Amigan -- AGI L'Aquila -- REB: http://web.tiscali.it/rebol/index.r