Transparency
Richmond Mathewson
geradamas at yahoo.com
Fri Feb 6 05:29:49 EST 2009
This works:
on mouseUp
set the transparent of img "Yellow.png" to true
put top of group "gX" into TOPP
put bottom of group "gX" into BUM
put left of group "gX" into LEFTT
put right of group "gX" into RITE
put LEFTT & "," & TOPP & "," & RITE & "," & BUM into fld "fRECT"
put fld "fRECT" into FRECT
put the windowID of this stack into WINDY
set the fileType to empty
set the width of img "HOLDER" to the width of group "gX"
set the height of img "HOLDER" to the height of group "gX"
export snapshot from rect FRECT of window WINDY to img "HOLDER" as PNG
set the width of img "HOLDER" to the width of img "Yellow.png"
set the height of img "HOLDER" to the height of img "Yellow.png"
set the alphaData of img "HOLDER" to the alphaData of img "Yellow.png"
export img "HOLDER" to file "GOTTIT.png" as PNG
end mouseUp
Obviously the reason I was getting 'Tiger Stripes' was that the image
"HOLDER" was not the same as the group "gX".
HOWEVER; the result is a PNG of the odd-shape with a 'cute' little,
white drop-shadow: I wonder why.
sincerely, Richmond Mathewson.
____________________________________________________________
A Thorn in the flesh is better than a failed Systems Development Life Cycle.
____________________________________________________________
More information about the use-livecode
mailing list