[GRASS5] Messages and GUI

Radim Blazek blazek at itc.it
Fri Nov 12 13:22:31 EST 2004


Glynn Clements wrote:
> Radim Blazek wrote:
> 
> 
>>I have added G_messages and modified a bit G_percent, G_warning
>>and G_fatal_error. If GRASS_MESSAGE_FORMAT enviroment (not GRASS) variable
>>is set to 'gui', those functions print messages in format
>>suitable for parsing by GUI. gui.tcl was also modified and
>>displays progress bar if G_percent is used and adds icons to output box.
>>http://mpa.itc.it/radim/g51/messages1.png
>>
>>Subject for discussion.
>>
>>Question: G_warning/G_messages/G_fatal_error can print more lines,
>>how to tell to GUI that it is one message?
> 
> 
> Print begin/end markers rather than a prefix in front of each line,
> e.g.
> 
> 	GRASS_INFO_WARNING
> 	message
> 	goes
> 	here
> 	GRASS_INFO_END

Cannot it happen that messages printed by a module and
a process created by the module (e.g. dbmi driver)
will be mixed together? For example:

GRASS_INFO_ERROR
module message 1
GRASS_INFO_ERROR
driver message 1
module message 2
module message 3
GRASS_INFO_END
driver message 2
GRASS_INFO_ERROR


Radim






More information about the grass-dev mailing list