[Qgis-developer] Two Questions about the QGIS API

Bob Bruce Bob.Bruce at gov.mb.ca
Sun Apr 26 12:38:55 EDT 2009


I have been starting to work with Python plugins and have encountered two
methods that don't seem to work and wondered if someone could help me to
understand what is happening?

In the QgsMapCanvas class there are two methods that I am having trouble
with:

zoomWithCenter - when I use the input coordinates that I type the view moves
to some strange location. For instance the current view is centered roughly
at: 330616E,6058767 and when I put in the coordinates 329946,6058707 in the
call to this method it moves roughly to the coordinates 603170,1047099.
Maybe I don't understand how I should call this method?

zoomByFactor: the documentation states: "Factor > 1 zooms in" however when I
call this with 0 < Factor < 1 it actually zooms in. When I call it with
Factor > 1 it zooms out. Is this an error in the documentation?

thanks,
            Bob Bruce
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/qgis-developer/attachments/20090426/497961e1/attachment.html


More information about the Qgis-developer mailing list