#117: r.digit: make guarantee_xmon fail nicely on WinGrass
-------------------------+--------------------------------------------------
  Reporter:  4everskiff  |       Owner:  [email protected]
      Type:  defect      |      Status:  new                      
  Priority:  minor       |   Milestone:  6.3.0                    
 Component:  Tcl         |     Version:  6.3.0 RCs                
Resolution:              |    Keywords:                           
-------------------------+--------------------------------------------------
Changes (by hamish):

  * priority:  major => minor
  * summary:  r.digit fails if launched from menu => r.digit: make
              guarantee_xmon fail nicely on WinGrass

Comment:

 AFAIK the Tcl version of v.digit works fine on native WinGrass, it's only
 menu items which call guarantee_xmon that won't work. Those are:

 {{{
 r.digit
 r.le.setup
 d.path.sh
 i.ortho.photo
 d.nviz
 }}}

 I have just modified guarantee_xmon in svn (r30966) to fail in a nicer way
 if there are no xmons*. It should really return with an error code, and
 menu items that call it should act like "guarantee_xmon && d.module" (I've
 no idea how to do that in tcl)

 [*] the error message is perhaps misleading if the user has 8 xmons
 already running, so no free ones. Feel free to improve it.

 nicer would be if those menu items were greyed out for WinGrass. again
 I've little clue how to do that in Tcl, but this is the shell code version
 that could be run at gui startup time before building the menus:
 {{{
 if [ `d.mon -L | grep -c '^x[0-9]'` -lt 1 ] ; then
   HAVE_XMON=0
 else
   HAVE_XMON=1
 fi
 }}}


 Hamish

-- 
Ticket URL: <http://trac.osgeo.org/grass/ticket/117#comment:10>
GRASS GIS <http://grass.osgeo.org>
GRASS Geographic Information System (GRASS GIS) - http://grass.osgeo.org/
_______________________________________________
grass-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-dev

Reply via email to