Hi devs,
there is a way to load an editable layer without editing capabilities?
I searched for a setCapabilities() method, but nothing.
Reducing the layer capabilities would be useful, especially for plugins,
obviously
without adding new capabilities.
In a C++ plugin I can extend the concrete DataProvider class.
There is a way to do the same thing in a python plugin? Maybe creating a
wrapper
to the layer dataProvider?
Something like:
class ReadOnlyProvider:
def __init__(self, dataProvider):
self.dataProvider = dataProvider
def select():
return self.dataProvider.select()
...
def capabilities():
return newCapabilites
should work, but the QgsVectorLayer.setDataProvider method is private...
Do you know other ways? Help is appreciated.
Thanks.
Cheers.
--
Giuseppe Sucameli
_______________________________________________
Qgis-developer mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/qgis-developer