[GRASS-dev] how to display a vector map for d.path in gis.m?

Glynn Clements glynn at gclements.plus.com
Tue Jan 30 07:45:57 EST 2007


Otto Dassau wrote:

> > > I used the d.path module in gis.m and found that the map I chose for calculating
> > > the shortest path is not automatically displayed in the background. So I have a
> > > white monitor where I can select my starting and end nodes to display a red
> > > line.
> > > 
> > > Is this missing or how do I have to use the module correctly in gis.m to display
> > > a vector map in the background? I used a grass cvs snapshot from today and tried
> > > with spearfish roads map.
> > 
> > 
> > d.path uses the old monitor system, not the new gis.m display, so when 
> > you launch it through the gis.m menu, an x-monitor opens (with something 
> > like Monitor: x0 written in the title bar). You can display whatever you 
> > want in this monitor by using the command line, e.g.:
> > 
> > d.vect roads
> 
> thanks for your help,
> 
> yes I saw that, but I think that it might  be more intuitive for a user to
> have the selected map for d.path visualized directly in the new x-monitor, when
> when you click on start.  
> 
> I mean, it is not an error, and of course one can easily type a d.vect roads
> command or whatever, but I found it strange that klicking on start you get an
> empty x-monitor and a usage desription for the mouse buttons in the Output
> monitor, but the map you selected in the d.path popup is not automatically
> displayed.
> 
> Maybe it is just my impression, so for me there is simply sth. missing. Could
> that not be added or is this difficult or not wanted?
> 
> maybe I should add a wish to the bugtracker... but I wanted to ask, if there is
> a special reason, why the selected map isn't displayed in the new x-monitor.

No reason; it's just the result of creating a menu tree for >300
commands without having the time to consider each one individually.

It wouldn't be particularly hard to write a script which accepts
exactly the same arguments as d.path, and which runs d.vect followed
by d.path.

Hmm; it might be useful to have some means of automatically generating
the corresponding g.parser description for a given command. There are
probably quite a few scripts whose options are (almost) identical to
an existing command. I'll look into it.

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




More information about the grass-dev mailing list