[GRASS5] Updated d.vect.thematic

Michael Barton michael.barton at asu.edu
Mon May 23 14:40:18 EDT 2005


Daniel

I used your awk code, as it is simpler than mine. I've attached a copy here.
I'm baffled as to why Moritz is getting a bad color value.

Moritz,

Try the new code here. If it doesn't work, please take a look at the ascii
group file that d.vec.thematic is creating. Where are the color values off?
Do you have a non-GNU version of AWK?

Michael


On 5/23/05 10:40 AM, "Daniel Calvelo Aros" <dcalvelo at minag.gob.pe> wrote:

> Hi Moritz,
> 
> Try to find the spots in the code having things like 'printf("#%2X%2X' in the
> awk code and change each of those "%2X" to "%02X", note the "0" which means
> "pad left with zeros".
> 
> This is a wild guess as I haven't seen the code, but Michael had just this
> sort of trouble yesterday night. Which also means it will get fixed very soon.
> 
> Daniel.
> 
> -- Daniel Calvelo Aros
> 
> ---------- Original Message -----------
> From: "Moritz Lennert" <mlennert at club.worldonline.be>
> To: "Michael Barton" <michael.barton at asu.edu>
> Cc: "Daniel Calvelo Aros" <dcalvelo at minag.gob.pe>, "Lorenzo Moretti"
> <lorenzo.moretti at bologna.enea.it>, "Jachym Cepicky"
> <jachym.cepicky at centrum.cz>, "grass devel" <grass5 at grass.itc.it>
> Sent: Mon, 23 May 2005 19:27:10 +0200 (CEST)
> Subject: Re: [GRASS5] Updated d.vect.thematic
> 
>> On Mon, May 23, 2005 19:07, Michael Barton said:
>>> OK,
>>> 
>>> I¹ve managed to add the option to save as a GIS Manager group (Thanks go  to
>>> Daniel for helping with parsing rgb into hex). I think this deals with most
>>> of the suggestions and updates that everyone made. Thanks to you all.
>> 
>> I get the following error when trying to load the group file (I've attached
>> the group file for info). Seems that the color codes are not completely
>> correct:
>> 
>> invalid color name "# 0 0FA"
>> invalid color name "# 0 0FA"
>>     (processing "-fill" option)
>>     invoked from within
>> "$leg create rectangle $x1 $y1 $x2 $y2 -outline $opt($id,color)
>> -fill $opt($id,fcolor)"
>>     (procedure "DmVector::legend" line 41)    invoked from within
>> "DmVector::legend $id"
>>     (procedure "DmVector::set_option" line 7)    invoked from within
>> "DmVector::set_option $current_node $key $val"
>>     ("vector" arm line 2)    invoked from within "switch $type {    
>>    group {     DmGroup::set_option $current_node $key $val        }  
>>    raster {     DmRaster::set_option $current_node $key $..."
>>     ("default" arm line 8)    invoked from within "switch $key {   
>>   Group {
>> 
>> if { [regexp -- {^File (.+)} $val r leftover]  && ($leftover !=
>> $::Dm::filename)} {
>> set val "<-- $leftover"..."
>>     (procedure "Dm::load" line 46)
>>     invoked from within
>> "Dm::load $::Dm::filename_new"
>>     (procedure "Dm::OpenFileBox" line 20)
>>     invoked from within
>> "Dm::OpenFileBox .mainframe.topf.tb1"
>>     ("uplevel" body line 1)
>>     invoked from within
>> "uplevel \#0 $cmd"
>>     (procedure "Button::_release" line 18)
>>     invoked from within
>> "Button::_release .mainframe.topf.tb1.bbox2.b1"
>>     (command bound to event)
> ------- End of Original Message -------
> 

____________________
C. Michael Barton, Professor of Anthropology
School of Human Evolution and Social Change
PO Box 872402
Arizona State University
Tempe, AZ  85287-2402
USA

Phone: 480-965-6262
Fax: 480-965-7671
www: <www.public.asu.edu/~cmbarton>

-------------- next part --------------
A non-text attachment was scrubbed...
Name: quartile_theme.dm
Type: application/octet-stream
Size: 2558 bytes
Desc: not available
Url : http://lists.osgeo.org/pipermail/grass-dev/attachments/20050523/0e95bcd0/quartile_theme.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: d.vect.thematic
Type: application/octet-stream
Size: 24400 bytes
Desc: not available
Url : http://lists.osgeo.org/pipermail/grass-dev/attachments/20050523/0e95bcd0/d.vect.obj


More information about the grass-dev mailing list