[Users] minResolution in layerTree
Andreas Hocevar
ahocevar at opengeo.org
Thu Dec 10 18:17:41 CET 2009
On 2009-12-10 17:57, Luca Casagrande wrote:
> Hi and thanks for your answer, Andreas.
> after your post I am planning to remove/add layers from the tree
> according to the resolution ( the Layer Tree example is a nice
> starting point).
> What do you think about?
>
Not a good idea. IMO the right place to show what is visible is the
legend. The tree is for the user to control what should be visible. When
you remove invisible layers from the tree, you take the control over
that layer from the user. A meaningful UI would gray out layers that are
invisible due to min/maxResolution constraints, but would still allow to
check/uncheck them.
And the effort to implement grayed-out layers should not be bigger than
adding/removing them based on min/maxResolution.
Having said that, contribution for grayed out layer nodes based on
min/maxResolution are welcome :-).
Regards,
Andreas.
> Thanks
> Ciao
>
> Luca
>
> On Thu, Dec 10, 2009 at 5:30 PM, Andreas Hocevar <ahocevar at opengeo.org> wrote:
>
>> Hi,
>>
>> when a layer changes from in range to out of range and vice verse,
>> GeoExt does not know about it. The OpenLayers layerswitcher listens to
>> the zoomend event of the map and walks through all layers, graying the
>> ones out of range out. We don't have this "grayed out" state for GeoExt
>> layer nodes.
>>
>> Have you tried the LegendPanel? I think the LegendPanel only shows
>> layers that are in range.
>>
>> Regards,
>> Andreas.
>>
>> On 2009-12-10 15:31, Luca Casagrande wrote:
>>
>>> Hello folks,
>>> moving my application from OpenLayers to GeoExt I had a problem with
>>> the maxResolution/minResolution attribute for a WMS layer:
>>> also if the mapPanel show the layer according to the resolution, in
>>> the layerTree it's always checked.
>>> Is there a way to "disable" an overlay layer using resolution values?
>>>
>>> Thanks
>>> Ciao
>>>
>>> Luca
>>> _______________________________________________
>>> Users mailing list
>>> Users at geoext.org
>>> http://www.geoext.org/cgi-bin/mailman/listinfo/users
>>>
>>>
>>
>> --
>> Andreas Hocevar
>> OpenGeo - http://opengeo.org/
>> Expert service straight from the developers.
>>
>>
>>
--
Andreas Hocevar
OpenGeo - http://opengeo.org/
Expert service straight from the developers.
More information about the Users
mailing list