Skip to content

Commit

Permalink
Polygon: apply the edge stroke also to the fill
Browse files Browse the repository at this point in the history
This leads also to better rendering on paths that are used in drawing characters.
  • Loading branch information
philippecade committed Dec 1, 2021
1 parent 7a4d239 commit 4645218
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/net/sf/jcgm/core/PolygonElement.java
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,11 @@ public String toString() {
public void paint(CGMDisplay d) {
Graphics2D g2d = d.getGraphics2D();

g2d.setStroke(d.getEdgeStroke());
d.fill(this.polygon);

if (d.drawEdge()) {
g2d.setColor(d.getEdgeColor());
g2d.setStroke(d.getEdgeStroke());
g2d.draw(this.polygon);
}
}
Expand Down

0 comments on commit 4645218

Please sign in to comment.