[REBOL] Re: EVOScript
From: ronaldoff::free::fr at: 27-Nov-2002 1:53
Hello Gabriele,
Tuesday, November 26, 2002, 10:52:42 AM, you wrote:
GS> Hi Ronald,
GS> On Tuesday, November 26, 2002, 10:50:23 AM, you wrote:
r>> Why does this change of shape happen ?
GS> Because you're overwriting the button effect:
>>> b: get-style 'btn
>>> print mold b/init
GS> [
GS> if size/x = -1 [
GS> either text [
GS> size/x: 1000
GS> state: size-text self
GS> size/x: either state [state/x + font/offset/x] [50]
GS> state: none
GS> ] [
GS> size/x: 50
GS> ]
GS> ]
GS> if font/colors [font/color: first font/colors]
GS> if not images [
GS> images: reduce [btn-up.png btn-dn.png]
GS> if not any [colors color] [color: 220.220.220]
GS> ]
GS> if images [image: images/1]
GS> if colors [color: colors/1]
GS> if all [image not effect] [
GS> effect: reduce ['extend image/size/2]
GS> if color [append effect reduce ['colorize color]]
GS> ]
GS> color: none
GS> ]
GS> Look at the part:
GS> if all [image not effect] [
GS> effect: reduce ['extend image/size/2]
GS> if color [append effect reduce ['colorize color]]
GS> ]
GS> you already provided an effect, so it is no more adding the EXTEND
GS> effect.
Not really a newbie, but far away from gurus, I'll have to dig into
the code to understand clearly what is happening, but to tired to do
it tonight ;-)
GS> Try with:
GS> Button "Pretty-print" effect [extend 22 multiply 255.150.0] [
GS> Regards, GS> Gabriele.
Thanks and @+
--
Best regards,
Ronald