[GRASS-dev] howto rewrite r.colors using G_message and G_warning
Jachym Cepicky
jachym.cepicky at centrum.cz
Tue Sep 26 05:17:42 EDT 2006
Hallo,
i have question considering replacing fprintf functions with G_message and G_warning in GRASS modules.
Currently, i come to r.colors, which structure is very complicated. This
module can be also run in interactive mode:
r.colors pokus color=rules
Enter rules, "end" when done, "help" if you need it.
Data range is 1 to 683
>
I'm not shure, if these strings should be printed using G_message or if
they should stay untouched. I'm also not shure, if the module needs this
interactive mode at all - if it should not better be removed (and the
structure of the module would be simplified).
If the interactive mode should remain untached, maybe functions
G_tty() and G_promt() should be introduced:
G_tty(_(Enter rules, "end" when done, "help" if you need it.));
G_promt()
which would show
Enter rules, "end" when done, "help" if you need it.
>
Could anybody give advice how to approach to modules like r.colors?
Thank you
jachym
--
Jachym Cepicky
e-mail: jachym.cepicky at centrum.cz
URL: http://les-ejk.cz
GPG: http://les-ejk.cz/gnupg_public_key/jachym_cepicky-gpg_public_key.asc
-----------------------------------------
OFFICE:
GDF-Hannover
Mengendamm 16d
30177 Hannover
Germany
e-mail: cepicky at gdf-hannover.de
URL: http://gdf-hannover.de
Tel.: +49 511-39088507
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 191 bytes
Desc: Digital signature
Url : http://lists.osgeo.org/pipermail/grass-dev/attachments/20060926/50fa409d/attachment.bin
More information about the grass-dev
mailing list