How to Apply a patch:<br>
<a href="http://trac.openlayers.org/wiki/ApplyingPatches">http://trac.openlayers.org/wiki/ApplyingPatches</a><br>
<br>
Made to order :-)<br>
<br><br><div><span class="gmail_quote">On 4/27/07, <b class="gmail_sendername">kaka</b> <<a href="mailto:drspencer@hotmail.com">drspencer@hotmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>Thanks for your reply and bug report. No, I am not sure of how to apply a<br>patch, is there documentation on this somewhere?<br><br>Magnus<br><br><br><br>Erik Uzureau-3 wrote:<br>><br>> sending again without the build OL patch -- msg too big for list :-)
<br>> erik<br>><br>> ---------- Forwarded message ----------<br>> From: Erik Uzureau <<a href="mailto:erik.uzureau@metacarta.com">erik.uzureau@metacarta.com</a>><br>> Date: Apr 25, 2007 8:15 PM<br>> Subject: Re: [OpenLayers-Users] Turning on/off layers depending on zoom
<br>> level<br>> To: kaka <<a href="mailto:drspencer@hotmail.com">drspencer@hotmail.com</a>><br>> Cc: <a href="mailto:users@openlayers.org">users@openlayers.org</a><br>><br>> Hello,<br>><br>> I have found some more time to look at this, and with your helpful
<br>> description I think I am able to see the problem (and maybe solve it).<br>><br>> The problem is that if the layer is out of range to start with, we never<br>> hide it. That's not good.<br>><br>> I am including a patch that seems to fix this problem in your code.
<br>><br>> Can you tell me if this fixes it for you?<br>><br>> If you don't know how to apply patches, I've also included a freshly build<br>> OL from trunk with this patch put in.<br>><br>> Please let me know if this fixes your problem. I would like to open a
<br>> ticket<br>> for this bug. It won't make it into the 2.4 release but in 2.5 for sure.<br>><br>> Thanks for your bug report and your patience with explaining it :-)<br>> Erik<br>><br>> On 4/22/07, kaka <
<a href="mailto:drspencer@hotmail.com">drspencer@hotmail.com</a>> wrote:<br>>><br>>><br>>> The problems I have with the maxResolution are:<br>>><br>>> a) the markers are dislocated. Have a look at the link I posted and try
<br>>> zooming out - the markers end up in the wrong positions.<br>>><br>>> b) the markers are visible when thy should not appear. I would like them<br>>> to<br>>> appear when I zoom in the map, and not on first load. However, I keep
<br>>> having<br>>> trouble with this. If they are set to show in the 0.03 resolution, the<br>>> example works just fine. If I set them to 0.02, or any other resolution<br>>> that<br>>> should make them not to render on first load, the example does no longer
<br>>> work as expected. The markers are drawn anyway and in the wrong location<br>>> as<br>>> mentioned in a).<br>>><br>>> Any help appreciated.<br>>><br>>> Magnus<br>>><br>
>><br>>><br>>> Erik Uzureau-3 wrote:<br>>> ><br>>> > Kaka,<br>>> ><br>>> > It is hard for people to help you because we need a more detailed<br>>> > description of the problem.
<br>>> > I personally do not understand what is going wrong here.<br>>> > Erik<br>>> ><br>>> > On 4/17/07, kaka <<a href="mailto:drspencer@hotmail.com">drspencer@hotmail.com</a>> wrote:
<br>>> >><br>>> >><br>>> >> Any help on this issue would be greatly appreciated. Could it be that<br>>> >> this<br>>> >> is<br>>> >> a bug? The example is over at
<br>>> >> <a href="http://www.villageografica.com/test44/Africa-test.html">http://www.villageografica.com/test44/Africa-test.html</a> and my problem<br>>> is<br>>> >> that the maxResolution doesn´t work with the zoom ranges I want and,
<br>>> >> also,<br>>> >> that the markers are not in the correct position.<br>>> >><br>>> >> Magnus<br>>> >><br>>> >><br>>> >><br>>> >>
<br>>> >> kaka wrote:<br>>> >> ><br>>> >> > This is an example of the problem I have:<br>>> >> ><br>>> >> > <a href="http://www.villageografica.com/test44/Africa-test.html">
http://www.villageografica.com/test44/Africa-test.html</a><br>>> >> ><br>>> >> > If I change the maxResolution to 0.2 the map works fine, but its<br>>> >> current<br>>> >> >
0.3 won´t work. I hope this illustrates my problem.<br>>> >> ><br>>> >> > Magnus<br>>> >> ><br>>> >> ><br>>> >> ><br>>> >> > Erik Uzureau-3 wrote:
<br>>> >> >><br>>> >> >> Dear Kaka,<br>>> >> >><br>>> >> >> Do you have a live example that you could post a link to?<br>>> >> >> Offhand, I can't see what the problem is... but I might be
<br>>> >> >> able to help you out if I could see it in action<br>>> >> >><br>>> >> >> Erik,<br>>> >> >> Best<br>>> >> >><br>>> >> >> On 4/10/07, kaka <
<a href="mailto:drspencer@hotmail.com">drspencer@hotmail.com</a>> wrote:<br>>> >> >>><br>>> >> >>> Thank you very much, Erik, this has been a great help. However, I<br>>> >> have
<br>>> >> >>> run<br>>> >> >>> into a problem. If the markers are set to not show on first load,<br>>> but<br>>> >> to<br>>> >> >>> appear when zooming in, the show/hide functionality stops working
<br>>> and<br>>> >> >>> the<br>>> >> >>> markers are dislocated when zooming out. My code looks like this:<br>>> >> >>><br>>> >> >>> var MarkersLayer2 = new
OpenLayers.Layer.Text( "Region info",<br>>> >> {location:<br>>> >> >>> "markers.txt", maxResolution: 0.03});<br>>> >> >>><br>>> >> >>> Changing the "
0.3" to "0.2" causes the problems mentioned above.<br>>> Is<br>>><br>>> >> this<br>>> >> >>> related to my code or a possible bug?<br>>> >> >>>
<br>>> >> >>> Magnus<br>>> >> >>><br>>> >> >>><br>>> >> >>><br>>> >> >>><br>>> >> >>> kaka wrote:
<br>>> >> >>> ><br>>> >> >>> > Hi<br>>> >> >>> > I am trying to turn on/off a layer of markers depending on zoom<br>>> >> level,<br>>> >> >>> > using google maps as a background layer. Does anyone have
<br>>> >> suggestions<br>>> >> >>> on<br>>> >> >>> > how to achieve this or is there or maybe an example? Thank you<br>>> for<br>>> >> any<br>>> >> >>> > ideas.
<br>>> >> >>> ><br>>> >> >>> > Regards,<br>>> >> >>> ><br>>> >> >>> > Magnus<br>>> >> >>> ><br>>> >> >>>
<br>>> >> >>> --<br>>> >> >>> View this message in context:<br>>> >> >>><br>>> >><br>>> <a href="http://www.nabble.com/Turning-on-off-layers-depending-on-zoom-level-tf3550126.html#a9927966">
http://www.nabble.com/Turning-on-off-layers-depending-on-zoom-level-tf3550126.html#a9927966</a><br>>><br>>> >> >>> Sent from the OpenLayers Users mailing list archive at <a href="http://Nabble.com">
Nabble.com</a>.<br>>> >> >>><br>>> >> >>> _______________________________________________<br>>> >> >>> Users mailing list<br>>> >> >>> <a href="mailto:Users@openlayers.org">
Users@openlayers.org</a><br>>> >> >>> <a href="http://openlayers.org/mailman/listinfo/users">http://openlayers.org/mailman/listinfo/users</a><br>>> >> >>><br>>> >> >> _______________________________________________
<br>>> >> >> Users mailing list<br>>> >> >> <a href="mailto:Users@openlayers.org">Users@openlayers.org</a><br>>> >> >> <a href="http://openlayers.org/mailman/listinfo/users">
http://openlayers.org/mailman/listinfo/users</a><br>>> >> >><br>>> >> >><br>>> >> ><br>>> >> ><br>>> >><br>>> >> --<br>>> >> View this message in context:
<br>>> >><br>>> <a href="http://www.nabble.com/Turning-on-off-layers-depending-on-zoom-level-tf3550126.html#a10048769">http://www.nabble.com/Turning-on-off-layers-depending-on-zoom-level-tf3550126.html#a10048769
</a><br>>><br>>> >> Sent from the OpenLayers Users mailing list archive at <a href="http://Nabble.com">Nabble.com</a>.<br>>> >><br>>> >> _______________________________________________
<br>>> >> Users mailing list<br>>> >> <a href="mailto:Users@openlayers.org">Users@openlayers.org</a><br>>> >> <a href="http://openlayers.org/mailman/listinfo/users">http://openlayers.org/mailman/listinfo/users
</a><br>>> >><br>>> ><br>>> > _______________________________________________<br>>> > Users mailing list<br>>> > <a href="mailto:Users@openlayers.org">Users@openlayers.org</a>
<br>>> > <a href="http://openlayers.org/mailman/listinfo/users">http://openlayers.org/mailman/listinfo/users</a><br>>> ><br>>> ><br>>><br>>> --<br>>> View this message in context:
<br>>> <a href="http://www.nabble.com/Turning-on-off-layers-depending-on-zoom-level-tf3550126.html#a10129213">http://www.nabble.com/Turning-on-off-layers-depending-on-zoom-level-tf3550126.html#a10129213</a><br>>>
<br>>> Sent from the OpenLayers Users mailing list archive at <a href="http://Nabble.com">Nabble.com</a>.<br>>><br>>> _______________________________________________<br>>> Users mailing list<br>>>
<a href="mailto:Users@openlayers.org">Users@openlayers.org</a><br>>> <a href="http://openlayers.org/mailman/listinfo/users">http://openlayers.org/mailman/listinfo/users</a><br>>><br>><br>><br>> _______________________________________________
<br>> Users mailing list<br>> <a href="mailto:Users@openlayers.org">Users@openlayers.org</a><br>> <a href="http://openlayers.org/mailman/listinfo/users">http://openlayers.org/mailman/listinfo/users</a><br>><br>
><br><br>--<br>View this message in context: <a href="http://www.nabble.com/Turning-on-off-layers-depending-on-zoom-level-tf3550126.html#a10217404">http://www.nabble.com/Turning-on-off-layers-depending-on-zoom-level-tf3550126.html#a10217404
</a><br>Sent from the OpenLayers Users mailing list archive at <a href="http://Nabble.com">Nabble.com</a>.<br><br>_______________________________________________<br>Users mailing list<br><a href="mailto:Users@openlayers.org">
Users@openlayers.org</a><br><a href="http://openlayers.org/mailman/listinfo/users">http://openlayers.org/mailman/listinfo/users</a><br></blockquote></div><br>