mouse within oval filled area
BNig
niggemann at uni-wh.de
Sun Nov 13 06:48:58 EST 2011
a simplifyed version of the "hack" to get at the boundaries of a oval with
startangle and arcangle set.
Again
to get the area of a oval graphic with a startangle and an arcangle set and
opaque = true you could use the new 5.0 intersect(object,object,"pixels")
syntax.
You would have to cheat though in that you create a hidden polygon graphic
"hidden" and call your start/arcangle graphic "halfCircle" plus a field for
feedback (for testing)
the script of the graphic "halfCircle":
-------------------------------------------------
on mouseWithin
set the points of grc "hidden" to the mouseLoc
if intersect(graphic "halfCircle", grc "hidden", "pixels") then
put the mouseColor && the milliseconds into field 1
else
put "" into field 1
end if
end mouseWithin
on mouseLeave
put "" into field 1
end mouseLeave
-------------------------------------------------
Depending on your needs you could change this to mouseMove.
Maybe it would be nice if the 'within' syntax would also have the option of
pixels. No more clunky workarounds.
within(object,point,"pixels")
Kind regards
Bernd
--
View this message in context: http://runtime-revolution.278305.n4.nabble.com/mouse-within-oval-filled-area-tp4034252p4036414.html
Sent from the Revolution - User mailing list archive at Nabble.com.
More information about the use-livecode
mailing list