[Qgis-user] Qgis Python plig-in. How can I change the nesting of groups?

dimamix at atrus.ru dimamix at atrus.ru
Mon Apr 4 23:09:44 PDT 2011



Hi.
Question about the groups and layers in the python  plug-in for (Qgis 
v.1.6)
#I created several groups.
grp1 = qgis.utils.iface.legendInterface (). addGroup ("grp1", -1)
grp2 = qgis.utils.iface.legendInterface (). addGroup ("grp2", -1)
#I created a layer of
vlayer = QgsVectorLayer ('c: \ data \ zu.tab', 'Zu', 'ogr')
#Move the layer into the group
QgsMapLayerRegistry.instance (). MoveLayer (vlayer, grp2)

How can I change the nesting of groups using Python?

ps
Sorry for the language



More information about the Qgis-user mailing list