Asking the impossible

J. Landman Gay jacque at hyperactivesw.com
Mon Dec 9 14:39:05 EST 2013


That's pretty clever Scott. Should have known you'd come up with 
something. :)

Rick, the image content used as the sources aren't rectangular, so just 
comparing the boundaries won't work. But it's a good concept for other 
uses, and thanks for the idea.


On 12/9/13 12:21 AM, Scott Rossi wrote:
> Are you ready for a kludge?
>
> You need the source image somewhere in your stack, and a 1x1 pixel graphic
> named "marker" placed on top of the source image.  In your test script:
>
> put formattedrect of the mouseCharChunk into theRect
>     put mouseH() - item 1 of theRect, mouseV() - item 2 of theRect into
> theOffset
>     set loc of grc "marker" to left of img "source" + item 1 of
> theOffset,top of img "source" + item 2 of theOffset
>     get intersect(grc "marker",img 1,"pixels")
>
>
> This will test the intersection of the marker graphic with the
> transparency of the image used as the image source.
> As I said, a kludge, but seems to work here.
>
> Regards,
>
> Scott Rossi
> Creative Director
> Tactile Media, UX/UI Design
>
>
>
>
> On 12/8/13 9:03 PM, "J. Landman Gay" <jacque at hyperactivesw.com> wrote:
>
>> I think this can't be done, but just in case:
>>
>> I have a transparent field that contains only an imagesource. It sits
>> over a larger image. I need to differentiate whether the user has
>> clicked on the imagesource content of the field or on its transparent
>> area.
>>
>> I know this can be done with a normal image object, but what about an
>> imagesource? Mousecolor won't work, there will always be a mousecolor.
>>
>> --
>> Jacqueline Landman Gay         |     jacque at hyperactivesw.com
>> HyperActive Software           |     http://www.hyperactivesw.com
>>
>> _______________________________________________
>> use-livecode mailing list
>> use-livecode at lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>
>
>
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>


-- 
Jacqueline Landman Gay         |     jacque at hyperactivesw.com
HyperActive Software           |     http://www.hyperactivesw.com




More information about the Use-livecode mailing list