[Users] Need Layer Tree examples for grouping several layers
Julien-Samuel Lacroix
jlacroix at mapgears.com
Mon Jul 26 17:32:07 CEST 2010
Hi,
In one of our application, what we did is adding "group" to the layer
options and filter on that.
loader: {
filter: function(record) {
return record.get("layer").options.group == "Group1"
},
This give us a layer customisable by groups of layer.
Julien
On 10-07-26 10:31 AM, Mehmet Sirin wrote:
> Hi,
> someone got some Layer tree examples? I need a couple to understand
> how it work, because the example at
> http://dev.geoext.org/trunk/geoext/examples/tree.html is only hard to
> understand.
> Examples based on what is explained here
> http://www.geoext.org/tutorials/layertree-tutorial.html would be nice.
> Or can you tell me how to realize my project: I have a few dynamically
> generated name for the parent-node and now I want to assign to each
> parent-node three child-nodes (three layer which contain vector
> features).
> Every layer should have one radiobutton in addition to the existing
> checkbox, also the parent-folder should have one radiobutton to
> activate or deactivate all three underlying layers.
>
> I think this is a basic and easy work..but I am not able to realize it.
>
> Maybe you want to know what I do not understand:
>
> - "y adding multiple named and filtered LayerContainers to a TreePanel
> you are able to provide logical organization to your layer trees" ..
> okay, that's what I need. But how to give over several LayerContainers
> in practise ? I tried to feed "root" in TreePanel with a array of
> layerContainer.. of course it does not work :D.
> -I have to use
>
> loader: {
> filter: function(record) {
> return record.get("layer").name.indexOf("Tasmania") !== -1
> },
>
> for choosing three certain layers? how would that look like`?
>
> - The "Three Nodes" example on Geoext website is somehow different to
> the stuff above (?).
> -- all of a sudden JSON.write (never used or heard) and something
> with "gx_baselayercontainer" etc. is in action. Looks like weird
> stuff.. As I'm writing this or complaining I understand why or when
> to use gx_baselayercontainer :-D .. but though i don't want to use
> this technique and still i don't know how to solve my above described
> problem.
>
>
> I hope you can give me some hints :)
> thank you
>
> regards
> m.sirin
> _______________________________________________
> Users mailing list
> Users at geoext.org
> http://www.geoext.org/cgi-bin/mailman/listinfo/users
>
--
Julien-Samuel Lacroix
Mapgears
http://www.mapgears.com/
More information about the Users
mailing list