[GRASS-dev] d.rast.edit in wxgrass
Daniel Calvelo
dca.gis at gmail.com
Mon Jun 25 23:48:46 EDT 2007
On 6/25/07, Glynn Clements <glynn at gclements.plus.com> wrote:
>
> How do we invoke the wxPython UI as a stand-alone process?
>
> For the Tcl/Tk UI, G_gui() essentially does:
>
> fp = popen("$GRASS_WISH", "w");
> fprintf(fp, "source $env(GISBASE)/etc/gui.tcl\n");
> generate_tcl(fp);
>
> We need an equivalent sequence for wxPython, e.g.:
>
> fp = popen("python", "w");
> fprintf(fp, /* WHAT GOES HERE ? */);
> generate_xml(fp);
>
> [There isn't a generate_xml() function at present; it's called
> G_usage_xml() and has stdout hardcoded, so that needs to be
> re-factored.]
Currently, menuform.py if run standalone will accept one argument, the
grass command, and will call it on its own to get back the
--xml-description. So an execve() should be enough, I think.
However, menuform.py should be stripped of most dependencies, such as
the cmd window.
Daniel.
--
-- Daniel Calvelo Aros
More information about the grass-dev
mailing list