mapfish-print icon indicating copy to clipboard operation
mapfish-print copied to clipboard

Feature request: Add "strokeLinejoin" attribute to style

Open romanzoller opened this issue 6 years ago • 2 comments

I would like to be able to configure the line join attribute for line strokes.

This is supported by geotools, but is currently not used in mapfish-print, it looks like geotools defaults to line join "miter".

Suggestion: Add attribute "strokeLinejoin" with the following possible values:

"strokeLinejoin" geotools constant
"bevel" LINE_JOIN_BEVEL
"miter" LINE_JOIN_MITRE
"round" LINE_JOIN_ROUND

(please please do not use the British spelling "mitre", it's not consistent with American spelling used everywhere else, such as "color" for example)

Relevant code in mapfish-print: https://github.com/mapfish/mapfish-print/blob/09307058a756c3504724fad56304733f59e1c8fc/core/src/main/java/org/mapfish/print/map/style/json/JsonStyleParserHelper.java#L797

romanzoller avatar Jun 05 '18 08:06 romanzoller

We have to follow what is specified by SLD (mitre): http://docs.geoserver.org/latest/en/user/styling/sld/reference/linesymbolizer.html#cssparameter

pvalsecc avatar Jun 06 '18 13:06 pvalsecc

Hmm, looks like this is already broken in the specification, because it says:

The graphical parameters and their values are derived from SVG/CSS2 standards with identical names and semantics.

The allowed values for line join are “mitre”, “round”, and “bevel”

Whereas the SVG specification says:

Value: miter | round | bevel | inherit

=> I would still be in favor of the American spelling for "Mapfish JSON Style Version 2".

romanzoller avatar Jun 06 '18 14:06 romanzoller