[mapserver-users] scaling labels

Alexander Shostko shostko at ureach.com
Tue Jul 9 21:49:38 PDT 2002


Dear Mapserver Users!

Thanks in advance for reading this message and for all possible 
hints and suggestions.

1. how can I make the class transparent (so other classes can 
set the color on the same shapes)in the same layer ?

e.g.

class
   expression( [level] lt 3.0 )
   # should be transparent, but allow other class to set the 
color. Only labels should be defined
   label

   end
end
class
   expression ( [perimeter] > 3.0 )
   color 23 23 23 
   outlinecolor 0 0 0 
end 

2. I use labeling based on the attributes (mapserver v 3.6 GIF 
version) and use CGI only.  However it uses
bitmap fonts and they do not scale at all. If I put 'type 
truetype, then no labels is shown at all.  What can be 
the possible reason.

The layer looks like:

  layer
    classitem 'STATE'
    data "statesp020"
    group "statesp020"
    labelcache on
    labelitem 'STATE'
    name "statesp020"
    postlabelcache true
    status on
    type polygon
  # red
    class
     EXPRESSION (  [LEVEL] ge 9.0 ) 
     color 255 0 0
     outlinecolor 72 61 139
     TEXT( [STATE] )
     label
       position auto
       font arial
       minsize 10
       maxsize 30
       mindistance 100
       buffer 100
       force true
       color 0 0 0 
    end
   end
    # 1 class statesp020_1
   class
     EXPRESSION ( [LEVEL] lt 2.0  )
     color 128 128 128
     outlinecolor 72 61 139
   end
  # green
   class
     EXPRESSION ( [LEVEL] ge 2.0 and [LEVEL] lt 4.0 ) 
     color 32 178 170
     outlinecolor 72 61 139
     TEXT( [STATE] )
     label
       type truetype
       position auto
       font arial
       minsize 10
       maxsize 30
       mindistance 100
       buffer 100
       force true
       color 0 0 0
    end
   end
end 



Thanks again for your time reading this message

Alexander Shostko






More information about the MapServer-users mailing list