[OpenLayers-Users] Question about popup location and creating graphical popups

Christopher Schmidt crschmidt at metacarta.com
Fri Mar 9 22:30:44 EST 2007


On Fri, Mar 09, 2007 at 03:29:17PM -0600, Keith wrote:
> Hello,
> 
>  
> 
> I've got 2 questions:
> 
>  
> 
> 1)       I'm using an anchored popup (OpenLayers.Popup.Anchored) to display
> data about features on a map.  Everything is working fine except the
> location of the popup seems to be varied.  The windows are definitely tied
> to the marker on the map, but it seems random what direction they popup in.
> This usually changes depending on which layer.  Ideally, I'd like the popups
> to appear to the southeast (with the northwest corner at the marker).  Does
> this have something to do with the OFFSET attribute of the anchor used in
> the constructor method?

The popup opens wherever there is the most available map space. This is
the primary purpose of the 'anchored bubble' popup. To change this
behavior, you'll probably want to look at extending the Popup.js.

Regards,
-- 
Christopher Schmidt
MetaCarta



More information about the Users mailing list