Hi Peter,
Nope, separating Graphic and Label elements in 2 different rules would of
course handle well the relative displacement but wouldn’t manage the labels
overlapping.
The labels overlapping is the main reason of using both Graphic and Label in
the same rule: it ensures that each Label is drawn over a Marker, then also
avoids the overlapping of different pairs Marker+Label.
My particular requirement is to have:
- a pair Marker+Label for each point
- pairs Marker+Label shall not overlap when zooming the map
- the Marker is centered on the point geom (X,Y)
- the Label is centered on the point geom (X+DELTAX,Y)
Something similar with the well-known case of roads shields (the road number in
the middle of a road marker) but where the road number is not centered on the
marker but it is written on the right side of the marker.
Did someone already find a solution to this?
Thanks,
Victor
> Date: Mon, 25 Jul 2016 12:51:25 +0200
> From: Peter Kovac
> <[email protected]<mailto:[email protected]>>
> Subject: Re: [Geoserver-users] SLD: Is it possible to get relative
> displacement between <Label> and <Graphic> in <TextSymbolyzer>?
> To:
> [email protected]<mailto:[email protected]>
> Message-ID:
> <[email protected]<mailto:[email protected]>>
> Content-Type: text/plain; charset=windows-1252; format=flowed
>
> Hi Victor,
> just split it into 2 rules: one for the graphic and one for the text label.
> Then you can use different displacement in each of them.
> Cheers,
> Peter
> On 25. 7. 2016 12:00, Victor.Sinceac wrote:
> > Hi All,
> >
> > In a SLD rule, I need to use a <TextSymbolizer> with both <Label> and
> <Graphic> elements (something similar to Highways Shields use case):
> > <Rule>
> > <TextSymbolizer>
> > <Label> ... </Label>
> > <Fill> ... </Fill>
> > <Halo> ... </Halo>
> >
> > <Graphic><Mark><WellKnownName>...</WellKnownName><Fill>...</Fill></Mark><Size>...</Size></Graphic>
> > </TextSymbolizer>
> > </Rule>
> > This works well when the requirement is to get the same position X,Y for
> > both Graphic and Label elements.
> > If I had well understood, the <LabelPlacement> element in such a rule
> > would apply to both elements Label and Graphic.
> > Is it possible to define in such a rule a displacement which would only
> > apply
> > to the element Label?
> > Thanks,
> > Victor
________________________________
This message is subject to and does not create or vary any contractual
relationship between Campbell Scientific Limited, its subsidiaries or
affiliates ("CSL") and you. Internet communications are not secure and
therefore CSL does not accept legal responsibility for the contents of this
message. The message is intended for the addressee only and its contents and
any attached files are strictly confidential. If you have received it in error,
please telephone +44 (0)1509 601141 or email [email protected].
Thank you.
Campbell Scientific Ltd.
Company Registration Number: 1933935 (England and Wales) Registered Address:
Campbell Park, 80 Hathern Road, Shepshed, Loughborough, Leicestershire LE12
9GX, UK
Tel: +44 (0) 1509 601141
Fax: +44 (0) 1509 601091
Web: www.campbellsci.co.uk
________________________________
------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are
consuming the most bandwidth. Provides multi-vendor support for NetFlow,
J-Flow, sFlow and other flows. Make informed decisions using capacity planning
reports.http://sdm.link/zohodev2dev
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users