When I use rotated horline or vertline like @Ian Turton suggested in his answer to question Rendering sld style(buffer) SEVERE null java.lang.NegativeArraySizeException, then I get breaks in the hatch, like on the image below. I can't find a way to get hatch without break. This hatch is rotated to the basis of an object by 45 degrees (so I can't use shape://slash), with different angles it looks even worse.
SLD suggested by @Ian
<PolygonSymbolizer>
<Geometry>
<ogc:Function name="buffer">
<ogc:PropertyName>the_geom</ogc:PropertyName>
<ogc:PropertyName>Buffer</ogc:PropertyName>
</ogc:Function>
</Geometry>
<Fill>
<GraphicFill>
<Graphic>
<Mark>
<WellKnownName>shape://horline</WellKnownName>
<Stroke>
<CssParameter name="stroke">
<ogc:PropertyName>COLOR</ogc:PropertyName>
</CssParameter>
<CssParameter name="stroke-width">2.5</CssParameter>
</Stroke>
</Mark>
<Rotation>Nagib</Rotation>
</Graphic>
</GraphicFill>
</Fill>