Skip to content
Permalink
Browse files
Fix for ticket #238 (zoom to map fails on startup). If there are no c…
…ommand line

 arguments, the extent is -1,-1,1,1, but if there, the extent is determined by t
he layers loaded.


git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5703 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
g_j_m committed Aug 17, 2006
1 parent 7716974 commit b2ce7e9ace1418795df31f2b271258eb9b6a293b
Showing with 7 additions and 2 deletions.
  1. +7 −2 src/gui/main.cpp
@@ -230,8 +230,13 @@ int main(int argc, char *argv[])
// save the image to disk and then exit
QString mySnapshotFileName="";

// This behaviour will set initial extent of map canvas
QString myInitialExtent="-1,-1,1,1";
// This behaviour will set initial extent of map canvas, but only if
// there are no command line arguments. This gives a usable map
// extent when qgis starts with no layers loaded. When layers are
// loaded, we let the layers define the initial extent.
QString myInitialExtent="";
if (argc == 1)
myInitialExtent="-1,-1,1,1";

// This behaviour will allow you to force the use of a translation file
// which is useful for testing

0 comments on commit b2ce7e9

Please sign in to comment.