[Geoserver-users] textsymbolizer - group is grouping across road classes

All,

I am labeling roads.
When I use <sld:VendorOption name="group">true</sld:VendorOption>
the grouping appears to be based on the label string alone.

This would be fine in many cases, but not the case I describe here.

Some of my roads have the same name across multiple functional classes.
For example, 10th street is class 4 along one section but class 3 along
another section.
When I label 10th street, the group fails to account for this problem.

Here is an example image:
http://www.nabble.com/file/p18327306/example.JPG example.JPG

Looking at "10th ST", we see that the line is blue and orange (class 4 and
3)
yet the only label is blue; as you can see it is on top of an orange street.

Here is the SLD:
http://www.nabble.com/file/p18327306/900913_map_stclines.xml
900913_map_stclines.xml

I have tried the following without success:
- quite a few variations on the SLD
- using separate layers
- using separate SLDs

I can think of some work some arounds:
- update the label fields based on the road class ("11th", "11th ", "11th
") (ugly)
- turn off halos (sad)
- update the road class values so they are all the same for a given name
(very ugly)

I hope to hear that I am missing something.

Regards,
Paul

--
View this message in context: http://www.nabble.com/textsymbolizer---group-is-grouping-across-road-classes-tp18327306p18327306.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

Paul McCullough ha scritto:

All,

I am labeling roads.
When I use <sld:VendorOption name="group">true</sld:VendorOption>
the grouping appears to be based on the label string alone.

Correct, that's the only way it works, labels are put into a
giant hash and then grouped when all the layers are done
drawing, there is no configuration allowing grouping to behave any differently.

I agree that the grouping should probably take into consideration
the symbolizer, that is, group labels only if they come out of
the same symbolizer (feature type style and rule are not visible
at the label handling level so they cannot be used). As things
are standing now, the grouping works globally only at the text
level, meaning that labels coming out of different layers will
be grouped if the are equal.
...

I can think of some work some arounds:
- update the label fields based on the road class ("11th", "11th ", "11th ") (ugly)
- turn off halos (sad)

Or use a neutral color for the halo.

- update the road class values so they are all the same for a given name
(very ugly)

I hope to hear that I am missing something.

Nope, you're not. Can you open a jira issue for this one?

Cheers
Andrea

Andrea,

Thanks for the feedback.
I have created the issue here:
    http://jira.codehaus.org/browse/GEOS-2029
I put it under geoserver.wms

Paul

--
View this message in context: http://www.nabble.com/textsymbolizer---group-is-grouping-across-road-classes-tp18327306p18342654.html
Sent from the GeoServer - User mailing list archive at Nabble.com.