I would have expected that the result of a dash of 30,30 would be a series of equal sized dashs and spaces.
The result looks more like 30 dash, 15 space repeated.
Line l3 = new Line(0, y, width, y);
l3.setStroke(Color.BLACK);
l3.setStrokeWidth(10);
l3.getStrokeDashArray().setAll(30.0, 30.0);
unless I set:
l3.strokeLineCapProperty().setValue(StrokeLineCap.BUTT);
in which case I do get equal spacing.
My expectation is that the should only affect the rendering of the end of the line and not the stroke pace in the middle.
The result looks more like 30 dash, 15 space repeated.
Line l3 = new Line(0, y, width, y);
l3.setStroke(Color.BLACK);
l3.setStrokeWidth(10);
l3.getStrokeDashArray().setAll(30.0, 30.0);
unless I set:
l3.strokeLineCapProperty().setValue(StrokeLineCap.BUTT);
in which case I do get equal spacing.
My expectation is that the should only affect the rendering of the end of the line and not the stroke pace in the middle.
- relates to
-
JDK-8093600 description of strokeDashArray attribute is unclear
- Resolved
-
JDK-8094685 StrokeDashArray with zero length dash has artifact if StrokeLineCap is SQUARE or ROUND
- Closed