Category:SVG simplification by dasharray

From Wikimedia Commons, the free media repository
Jump to: navigation, search

The SVG attribute stroke-dasharray can be used to draw dotted lines, but as well for much more. The example 5lines pg a.svg shows that it can fill an area.

Dice-5sqa.svg Dice-5.svg Dice-5sqb.svg

An interesting possibility is the dash of length zero; see more at Dasharray.
When stroke-linecap is defined e.g. as round, the renderer generates objects in the distance of the gaps and in the size of the stroke-width, as shown in the three examples.

This logic allows to draw graphics like all the Braille letters or dice very easy.

Note: The renderer sometimes has difficulties when the path ends exactly at the position of a zero-length dash;
therefore it is advised to make the path a bit longer.
The example SVGpathM03.svg explains it and shows different views depending on rendering size.

Media in category "SVG simplification by dasharray"

The following 54 files are in this category, out of 54 total.