[GRASS-dev] Re: grass-dev Digest, Vol 15, Issue 37

Michael Barton michael.barton at asu.edu
Fri Jul 27 14:08:46 EDT 2007


Tom,

If you want to play around with TclTk a bit, you could simply add a line or
two in one of the currently existing menus (all in
$GISBASE/etc/gm/gmmenu.tcl) to do a specific task. For example, you could
add a menu entry that could have for its command: "v.surf.bspline
input=wstation_temp raster=tempmap type=bicubic column=temp"

This would take a file of vector weather station points named
"wstation_temp", with an attribute column named "temp", and use bicubic
interpolation to create a temperature surface named "tempmap"

Here is a bit of script that could be inserted into the raster menu to add a
submenu for doing weather-related raster modeling

{separator}
{cascad {[G_msg "Weather modeling"]} {} "" $tmenu {
   {command {[G_msg "temperature surface"]} {} "bicubic interpolation
           of weather station temperature data" {} -command {execute
           v.surf.bspline input=wstation_temp raster=tempmap type=bicubic
           column=temp }}
   {separator}
   {command {[G_msg "another menu entry"]} {} "put the help text here" {}
           -command {execute GRASSCOMMAND }}
}}

{separator} inserts a line separating menu items
{cascad... } creates a submenu
{command...} creates a menu entry that starts a command.

Maybe this can help you show how easy it is to make custom menu entries.
Hope this is helpful.

Michael

On 7/27/07 10:23 AM, "grass-dev-request at grass.itc.it"
<grass-dev-request at grass.itc.it> wrote:

> Send grass-dev mailing list submissions to
> grass-dev at grass.itc.it
> 
> To subscribe or unsubscribe via the World Wide Web, visit
> http://grass.itc.it/mailman/listinfo/grass-dev
> or, via email, send a message with subject or body 'help' to
> grass-dev-request at grass.itc.it
> 
> You can reach the person managing the list at
> grass-dev-owner at grass.itc.it
> 
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of grass-dev digest..."
> Today's Topics:
> 
>    1. Re: r.terraflow on Mac OS X 10.4.9 (Michael Barton)
>    2. Re: r.terraflow on Mac OS X 10.4.9 (Helena Mitasova)
>    3. Re: [GRASS-user] GRASS "custom" applications (Thomas Adams)
>    4. Re: [GRASS-user] Re: [GRASS-dev] GRASS "custom" applications
>       (Thomas Adams)
>    5. Re: Re: gis.m: font selection in module panels (Paul Kelly)
>    6. Re: Re: [GRASS-user] GRASS "custom" applications (Paul Kelly)
> _______________________________________________
> grass-dev mailing list
> grass-dev at grass.itc.it
> http://grass.itc.it/mailman/listinfo/grass-dev

__________________________________________
Michael Barton, Professor of Anthropology
Director of Graduate Studies
School of Human Evolution & Social Change
Center for Social Dynamics and Complexity
Arizona State University

phone: 480-965-6213
fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton 




More information about the grass-dev mailing list