[GRASS-user] Re: [GRASS-dev] Region setting correction

Glynn Clements glynn at gclements.plus.com
Sat Aug 19 05:01:16 EDT 2006


Michael Barton wrote:

> BUT (and a very confusing one at that), g.region run from the command line
> and g.region run from the menus do NOT always behave the same way with
> regard to the interactive zooming in a display. I have no idea why this is
> so. Maybe someone else can enlighten me.

The only plausible explanation is that WIND_OVERRIDE isn't always
being unset before g.region is run from gis.m, resulting in g.region
modifying something other than the WIND file.

In fact, AFAICT, WIND_OVERRIDE will always be set; searching for
WIND_OVERRIDE in gui/tcltk/gis.m indicates that the only places it is
ever unset are in procedures (georect.tcl and mapcanvas.tcl) which
subsequently set it. Thus any command run from gis.m will read (and
possibly write) the saved region for the most recently used display,
not the WIND file.

Also, as the <FocusIn> handler for each canvas sets WIND_OVERRIDE, its
value can change at any time.

-- 
Glynn Clements <glynn at gclements.plus.com>




More information about the grass-user mailing list