sdext,pdfimport: Fix stroke clipping

The bounding clipping I added back in:
  abfbca2719 ("tdf#85428: Clip strokes")

breaks 'thick' closed polygons, losing the closed flag.
That's fixed by changing the bStroke flag to the clipper
like done in svdpdf.cxx and svdfmtf.cxx

This fixes the rendering of the top right box in:
  https://gitlab.freedesktop.org/poppler/poppler/-/issues/178

Change-Id: Ib2ef27bef9860420b231cceaa2b0568c443d7f2e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/187435
Tested-by: Jenkins
Reviewed-by: David Gilbert <freedesktop@treblig.org>
This commit is contained in:
Dr. David Alan Gilbert
2025-07-05 01:52:21 +01:00
committed by David Gilbert
parent 34532f7b1b
commit 2f2f56f47f

View File

@ -458,7 +458,7 @@ void PDFIProcessor::strokePath( const uno::Reference< rendering::XPolyPolygon2D
if( aCurClip.count() ) {
aPoly = basegfx::utils::clipPolyPolygonOnPolyPolygon( aPoly, aCurClip,
true, /* bInside, keep parts inside the clip */
true /* bStroke, stroked */ );
!aPoly.isClosed() /* bStroke */ );
}
PolyPolyElement* pPoly = ElementFactory::createPolyPolyElement(