Hello dear list,

in  the process of developing a plugin (python 2.7, QGIS 2.6),

from pyqgis ,
we would like to refresh a Postgis layer.
When using the vectorLayer.refresh(), it does nothing.

We used a trick that works but seems like a bad idea :
(we slightly change the zoom to force rendering)
DEFAULT_SEGMENT_EPSILON = 1E-8
mapCanvas().zoomByFactor(1.0 + DEFAULT_SEGMENT_EPSILON, mapRect.center())

Somebody knows how to do it properly?
Thanks,
Rémi-C
_______________________________________________
Qgis-developer mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/qgis-developer

Reply via email to