[GRASS-SVN] r29522 - grass/trunk/gui/tcltk/gis.m

svn_grass at osgeo.org svn_grass at osgeo.org
Thu Dec 27 11:35:53 EST 2007


Author: cmbarton
Date: 2007-12-27 11:35:53 -0500 (Thu, 27 Dec 2007)
New Revision: 29522

Modified:
   grass/trunk/gui/tcltk/gis.m/mapcanvas.tcl
Log:
Improvement to region setting algorithm for display

Modified: grass/trunk/gui/tcltk/gis.m/mapcanvas.tcl
===================================================================
--- grass/trunk/gui/tcltk/gis.m/mapcanvas.tcl	2007-12-27 15:27:47 UTC (rev 29521)
+++ grass/trunk/gui/tcltk/gis.m/mapcanvas.tcl	2007-12-27 16:35:53 UTC (rev 29522)
@@ -593,8 +593,7 @@
 			Gm::errmsg $error [G_msg "Error setting region"]
 		}
 		# Finally put this into wind file format to use with GRASS_REGION
-		regexp -nocase {^.* (\(.*\))} $parts(projection) trash end
-		set parts(projection) [string trim $parts(projection) $end]
+		regexp -nocase {^([0-9]+)} $parts(projection) trash parts(projection)
 
 		set gregion "projection:$parts(projection); zone:$parts(zone); north:$parts(north); south:$parts(south); east:$parts(east); west:$parts(west); e-w resol:$parts(ewres);	 n-s resol:$parts(nsres)"
 	} 



More information about the grass-commit mailing list