RE: [OpenMap Users] getting highlight() called from inside an OMRect

From: Andrew Schulak <aschulak_at_gestalt-llc.com>
Date: Wed, 30 Mar 2005 15:27:06 -0500

Rick, thanks for the speedy response,
 
Is there a better way to find the OMRects at the spot clicked rather
than iterating over the complete set of all of my OMRects?
 
Thanks,
A

-----Original Message-----
From: Rick Lane [mailto:lane_richard_b_at_bah.com]
Sent: Wednesday, March 30, 2005 3:10 PM
To: Andrew Schulak; openmap-users_at_bbn.com
Subject: RE: [OpenMap Users] getting highlight() called from inside an
OMRect



Andrew,

 

My application uses boxes similarly to how you're describing. If you're
wondering how to get the transparency, simply create a Color object with
a less-than-255 value for the alpha component:

 

Color transColor = new Color(255, 0, 0, 100); // This will create a
red color that is transparent

 

Then you can call setFillPaint() with this color.

 

If you're wondering how to highlight when the mouse is inside the
OMRect, then modify the mouseMoved(MouseEvent) function in your layer to
find which OMRects are currently at the current mouse position, and call
select() accordingly.

 

Rick

 

 


  _____


From: owner-openmap-users_at_bbn.com [mailto:owner-openmap-users_at_bbn.com]
On Behalf Of Andrew Schulak
Sent: Wednesday, March 30, 2005 2:56 PM
To: openmap-users_at_bbn.com
Subject: [OpenMap Users] getting highlight() called from inside an
OMRect

 

All,

 

I have a bunch of OMRects in an OMGraphicHandlerLayer. I would like the
highlight() and select() methods to be called when the mouse is inside
the OMRect as well as (or rather than) when it is only on the edge?

 

Is there a way to get this functionality?

 

I would not be opposed to using something other than an OMRect, my only
constraint is that it be a bordered box that is clear/transparent in the
middle.

 

Thanks,

Andrew

 



--
[To unsubscribe to this list send an email to "majdart_at_bbn.com"
with the following text in the BODY of the message "unsubscribe openmap-users"]
Received on Wed Mar 30 2005 - 15:27:41 EST

This archive was generated by hypermail 2.3.0 : Tue Mar 28 2017 - 23:25:06 EDT