Hello, 2012/3/26 David MENTRE <[email protected]>: > 2012/3/26 David MENTRE <[email protected]>: >> Like in case 1, we would like to split the long name over several >> lines. How can we do this with Mapnik2? Any pointer to relevant >> documentation and examples? > > We are making some progress. We are now able to have smaller names > with following TextSymbolizer (using > placements="E,W,N,S,9,8,7,6,5,4,3,2,1") : > > <Rule> > <Filter>(([highway]='unclassified') or > ([highway]='residential'))</Filter> > <MinScaleDenominator>5000</MinScaleDenominator> > <MaxScaleDenominator>12500</MaxScaleDenominator> > <TextSymbolizer fontset-name="book-fonts" size="9" > fill="rgb(255,0,0)" placement="line" vertical-alignment="auto" > halo-radius="1" wrap-character="\n" wrap-width="5" wrap-before="true" > line-spacing="9" spacing="300" max-char-angle-delta="40" > allow-overlap="true" horizontal-alignment="auto" > placement-type="simple" > placements="E,W,N,S,9,8,7,6,5,4,3,2,1">[name]</TextSymbolizer> > </Rule> > > > However, we are not able to obtain street name on several lines. Is > there a specific attribute of TextSymbolizer to set?
After looking at Mapnik2 source code, it appears that wrapping algorithm is apparently not called if placement="line" (it is only called for placement="point"). Would anybody see a workaround to keep placement="line" while keeping wrapping for long names? Best regards, david
