[mapserver-users] Possible Bug? use Style with Offset and Color from DB twice in one class section

Ralf Trier Ralf.Trier at logos-ib.de
Tue Jul 26 02:13:33 PDT 2011


Hello, 

I want to draw two parallel lines to baselines from a database. The
parallel lines should be drawn with the color set in the db. 

Part of my map file:

LAYER
	NAME "tttt"
	TYPE LINE
	PROJECTION
		"init=epsg:900913"
	END
	STATUS DEFAULT
	CONNECTIONTYPE postgis
	CONNECTION "host=192.168.1.10 dbname=xxx user=xxx"
	DATA "way from (select id, color01, color02, way from myTable)
as foo using unique id using srid=900913"
	SIZEUNITS pixels
	CLASS 
		STYLE
			OFFSET 5 -99
			COLOR [color01]
			WIDTH 10
			LINECAP square
		END
		STYLE
			OFFSET -5 -99
			COLOR [color02]
			WIDTH 10
			LINECAP square
		END
	END 
END

Strange think happens. The first parallel line is drawn with the
expected color. The second line (second style instruction) will be drawn
in a random color seems to come from another line. The color (second
line) will change depending form the scale.

Any ideas?

Thanks
Ralf




More information about the MapServer-users mailing list