Skip to content

Render stroke-only custGeom line shapes#150

Merged
SimonCropp merged 1 commit into
mainfrom
Render-stroke-only-custGeom-line-shapes
Jul 8, 2026
Merged

Render stroke-only custGeom line shapes#150
SimonCropp merged 1 commit into
mainfrom
Render-stroke-only-custGeom-line-shapes

Conversation

@SimonCropp

Copy link
Copy Markdown
Member

Thin decorative rules built as a custom-geometry line segment (moveTo + lnTo) with a stroke and no fill were dropped: ParseSolidFillShape bailed whenever a shape had no fill, and ExtractSubpaths discarded contours with fewer than three points. The Agenda template's left/top accent rules (agendas-minutes/10) went missing across every backend as a result.

Emit a stroke-only FloatingShapeElement when a shape has a stroke but no fill, carrying its flattened Subpaths (open two-point contours kept via a new minContourPoints). All backends already stroke Subpaths, so Skia, ImageSharp, PDF and the HTML export pick it up unchanged. Filled shapes keep the three-point minimum and never gain an outline, so their output stays byte-identical.

Gate the new path to solid dashes: a dashed outline drawn solid looks worse than not drawing it (matching ParseLineShape), so letterhead decorations like letters/05's dashed rules stay unrendered rather than becoming solid bars.

Thin decorative rules built as a custom-geometry line segment (moveTo +
lnTo) with a stroke and no fill were dropped: ParseSolidFillShape bailed
whenever a shape had no fill, and ExtractSubpaths discarded contours with
fewer than three points. The Agenda template's left/top accent rules
(agendas-minutes/10) went missing across every backend as a result.

Emit a stroke-only FloatingShapeElement when a shape has a stroke but no
fill, carrying its flattened Subpaths (open two-point contours kept via a
new minContourPoints). All backends already stroke Subpaths, so Skia,
ImageSharp, PDF and the HTML export pick it up unchanged. Filled shapes
keep the three-point minimum and never gain an outline, so their output
stays byte-identical.

Gate the new path to solid dashes: a dashed outline drawn solid looks
worse than not drawing it (matching ParseLineShape), so letterhead
decorations like letters/05's dashed rules stay unrendered rather than
becoming solid bars.
@SimonCropp SimonCropp added this to the 1.1.4 milestone Jul 7, 2026
@SimonCropp SimonCropp merged commit da3c4cc into main Jul 8, 2026
4 checks passed
@SimonCropp SimonCropp deleted the Render-stroke-only-custGeom-line-shapes branch July 8, 2026 00:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant