On Fri, Jul 01, 2016 at 06:47:16PM +0200, Martin Dobias wrote: > I think what you are up to is not to find out scale(), but actually > mapUnitsPerPixel(). Scale in QGIS is calculated as ( extent_width / ( > canvas_width * dpi) ) with some extra conversions involved, see > QgsScaleCalculator class.
Thanks, with the show() trick, mapUnitsPerPixel() works as expected (while scale() still gives wild returns, maybe due to wild dpis..) --strk; _______________________________________________ Qgis-developer mailing list [email protected] List info: http://lists.osgeo.org/mailman/listinfo/qgis-developer Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-developer
