Both PDFs and SVGs allow setting linecaps to:
We currently only the first (in Path::stroke_to_fill() in Path.cpp).
Implementation-wise, this should be easier to do than the round circles: At the start, add a point perpendicular to the start direction (and initialize the angle right). Then at the other end, add two points, and back at the start the missing one.
Some PDFs use wide lines with butt caps to draw rectangles for some reason. In some PDFs, tables draw their vertical lines as very wide horizontal lines with butt caps. Since we currently only support round caps, this results in:
(At slightly different page sizes, it sometimes looks like so instead, suggesting the round cap rendering is somewhat sensitive to floating point stuff and not always quite right:
But that's a separate bug.)
It's not always so dramatic. Here, the blue roundrects are supposed to be rectangles:
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too