[GRASS-dev] Re: #339: d.mon doesn't work (WinGrass commandline)
glynn at gclements.plus.com
Mon Oct 20 19:01:28 EDT 2008
Paul Kelly wrote:
> > One limitation of ximgview is that it only works for mmap()d BMP
> > files. The reason for this is so that it will never have to deal with
> > an incomplete file.
> > To use it:
> > export GRASS_PNGFILE=map.bmp
> > # create the file
> > d.erase
> > export GRASS_PNG_MAPPED=TRUE
> > export GRASS_PNG_READ=TRUE
> > ximgview map.bmp
> > Also, you can set:
> > export GRASS_NOTIFY="kill -USR1 `pidof ximgview`"
> > This will cause R_close_driver() to send a signal to ximgview to
> > update the display, rather than waiting for it to poll. In that
> > situation, pass percent=1 to ximgview (percent=0 causes a
> > divide-by-zero).
> Something like the above wrapped up in a script called d.mon would I
> suspect go a reasonable way towards satisfying people looking for a
> quick-and-easy way of displaying a few maps.
Unfortunately, the environment settings can't easily be wrapped up
into a script (unless the script were to spawn a child shell).
A more realistic solution would be to print an error message along
with a link to a wiki page explaining the alternatives.
Better still would be the option to have d.* commands interact with
the GUI. This would be simpler if wxPython included bindings for the
wxClient and wxServer classes (DDE on Windows, TCP on Unix), but it
Glynn Clements <glynn at gclements.plus.com>
More information about the grass-dev