Chapter 9. Stroke and Markers
While relatively rare in artistic drawings, stroked paths—outlines, frames, arrows, connectors, and so on—are very common in technical drawings such as drafts or flowcharts. A sizable share of all SVG style properties control the appearance of stroke, which therefore deserves a chapter of its own.
While stroking in SVG is quite rich and adequate for a lot of purposes, some things you may be looking for are simply not there, or are only available via workarounds. In particular, SVG stroke always has constant width (it cannot get wider or narrower along the path); to emulate variable-width stroke, use the Calligraphic pen (14.3 The Calligraphic Pen Tool) or path effects (13.1 Path Effects). Also, while stroke can have ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access