Hi Giovanni, On Tue, Nov 27, 2012 at 3:26 AM, G. Allegri <[email protected]> wrote: > I need to replicate the theming of a vector layer to another one. > I thought that cloning the oringinal renderer (being it V2 or not) and > applying it to other layer would be enough, but id doesn't have effects. The > other layer is applied the default (random) styling. > Probably I've misunderstood the renderer mechanism. How should one procede > to obtain it?
I just exposed QgisApp's mActionCopyStyle and mActionPasteStyle to QgisInterface [0]. Is this what you are looking for (in Python)? Usage: iface.setActiveLayer( someQgsMapLayer ) iface.actionCopyLayerStyle().trigger() iface.setActiveLayer( someotherQgsMapLayer ) iface.actionPasteLayerStyle().trigger() Regards, Larry [0] https://github.com/qgis/Quantum-GIS/commit/b9b943d5e1580bdc17435598dd5be41eb0c2a853 > giovanni > > _______________________________________________ > Qgis-developer mailing list > [email protected] > http://lists.osgeo.org/mailman/listinfo/qgis-developer > _______________________________________________ Qgis-developer mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/qgis-developer
