[GRASS-dev] [GRASS GIS] #2382: d.legend: integer map legends should not be flipped upside-down

GRASS GIS trac at osgeo.org
Mon Aug 4 17:24:58 PDT 2014


#2382: d.legend: integer map legends should not be flipped upside-down
----------------------+-----------------------------------------------------
  Reporter:  neteler  |       Owner:  hamish             
      Type:  defect   |      Status:  closed             
  Priority:  normal   |   Milestone:  7.0.0              
 Component:  Display  |     Version:  svn-releasebranch70
Resolution:  wontfix  |    Keywords:  d.legend           
  Platform:  All      |         Cpu:  Unspecified        
----------------------+-----------------------------------------------------

Comment(by hamish):

 > "smoothed" legend != "gradient" legend

 Hi,

 I was thinking a bit more about this, maybe a way around the ambiguity of
 what kind of data a CELL map contains is for d.legend to test if the
 `r.support units=` has been set and has a string length > 0, and if it
 contains a value assume it is a continuous gradient map, and so smallest
 value on the bottom.

 I fear it moves a bit into 'too tricky for its own good' territory, the
 existing help text is nicely concise, but apparently what to expect is not
 obvious if you haven't read that. I guess since it talks about
 "categorical" and not CELL maps, the text wouldn't have to change for a
 continuous gradient CELL map? Seems a bit of a stretch & I don't want to
 introduce more confusion..

 {{{
        Raster maps based on  floating  point  values  will
        display  smoothed, from greatest to smallest value,
        while categorical raster maps will display in order,
        from  top to bottom. Horizontal legends will always
        be smoothed. If the box is defined with inverted y-
        values  or an inverted range, the legend will auto-
        matically flip. If this is not the desired  result,
        the -f flag may be used to flip it back.
 }}}


 messy!

 Hamish

-- 
Ticket URL: <https://trac.osgeo.org/grass/ticket/2382#comment:7>
GRASS GIS <http://grass.osgeo.org>



More information about the grass-dev mailing list