[Geoserver-users] Label each part of a multipolygon

I try to label each part of multpolygons but have no success.
Only the largest part is labelled regardless of the tested options. What I am missing?

SLD options tested - with true/false and on/off
false
true

with goodnessOfFit set to 0 to always label all minor polygons
0

Using GeoServer 1.7.6, shapefile as datasource

Best Regards



Andreas Oxenstierna

Telefon direkt 040-16 70 17
Mobil 0734-12 80 17
andreas.oxenstierna@anonymised.com

Sweco Position AB

Hans Michelsensgatan 2
Box 286
201 22 Malmö
Telefon 040-16 70 00
www.sweco.se







On Thu, Jan 28, 2010 at 7:24 AM, Oxenstierna Andreas <Andreas.Oxenstierna@anonymised.com> wrote:

I try to label each part of multpolygons but have no success.
Only the largest part is labelled regardless of the tested options. What I am missing?

That is the correct behaviour - the only thing I can suggest is to split your multipolygons in to a bunch of polygons.

Ian

Ian Turton

According to Andrea Aime in http://old.nabble.com/SLD-grouping-labels-on-a-polygon-td17623472.html
GeoServer should label each polygon in a multipolygon.
Has this behaviour changed since June 2008?

Best Regards



Andreas Oxenstierna

Telefon direkt 040-16 70 17
Mobil 0734-12 80 17
andreas.oxenstierna@anonymised.com

Sweco Position AB

Hans Michelsensgatan 2
Box 286
201 22 Malmö
Telefon 040-16 70 00
www.sweco.se







<
Please consider the environment before printing my e-mail.


Från: Ian Turton [mailto:ijturton@anonymised.com84…]
Skickat: den 28 januari 2010 19:23
Till: Oxenstierna Andreas
Kopia: geoserver users
Ämne: Re: [Geoserver-users] Label each part of a multipolygon

On Thu, Jan 28, 2010 at 7:24 AM, Oxenstierna Andreas <Andreas.Oxenstierna@anonymised.com…> wrote:

I try to label each part of multpolygons but have no success.
Only the largest part is labelled regardless of the tested options. What I am missing?

That is the correct behaviour - the only thing I can suggest is to split your multipolygons in to a bunch of polygons.

Ian

Ian Turton

Oxenstierna Andreas ha scritto:

According to Andrea Aime in http://old.nabble.com/SLD-grouping-labels-on-a-polygon-td17623472.html
GeoServer should label each polygon in a multipolygon.
Has this behaviour changed since June 2008?

The behavior has not changed. I was just wrong.
Given a group of polygons they first get clipped and then
the biggest one of them is used as the label container.

There is currently no way to make the labeler paint a
label in each of the multipolygon elements, though it
could be done by making the polygon labelling
support "labelAllGroup" (atm it works only against lines).

Cheers
Andrea

--
Andrea Aime
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.