Category:SVG simplification by linecapping
Often it is possible to draw circle structures with the stroke-linecap=round
attribute, or rectangular ones with stroke-linecap=square
.[clarification needed]
Examples how to draw a circle

There are different possibilities to draw a simple bordered circle as shown with this example.
- Bad solution: Very complicated drawing with cubic arcs (not a true trigonometric circle !)[clarification needed]
- conventional:
<circle fill="#FEDE58" stroke="#000" stroke-width="10.5" x="175" cy="175" r="154"/>
or in relatives:<circle fill="#FEDE58" stroke="#000" stroke-width="3%" cx="50%" cy="50%" r="44%"/>
- with linecapping: needs two paths,
outside border<path d="m175,175h0" stroke-width="318.5" stroke-linecap="round" stroke="#000"/>
and inside disk<path d="m175,175h0" stroke-width="298.5" stroke-linecap="round" stroke="#FEDE58"/>
[clarification needed] - with the "a" element[clarification needed]: as a true circle
<path fill="#FEDE58" stroke="#000" stroke-width="10.5" d="m175,21a154,154 0 1,0 0,308 154,154 0 1,0 0-308"/>
- or shortened (not a true trigonometric circle – but for most cases the small flat interval won't matter)
<path fill="#FEDE58" stroke="#000" stroke-width="10.5" d="m174,21a154,154 0 1,0 2,0z"/>
- or shortened (not a true trigonometric circle – but for most cases the small flat interval won't matter)
While the shortened version of (4) will be the best solution for simple drawings, linecapping as in (3) can be an advantage, esp. when used with the stroke-dasharray attribute.
Needless to say that a mere disk without the border becomes simpler.
Pages in category "Category:SVG simplification by linecapping"
- Category:SVG simplification by linecapped dasharray
- File:Anti-GeoGebra.svg
- File:Aspecto do sinal nº 9 de tempestade tropical de Macau em noite.svg
- File:Color guide flags.svg
- File:Ecuador Asamblea 2021.svg
- File:Equiangular pentagon 00.svg
- File:Flag of Vietnamese Republic (Beistean).svg
- File:Geogebra.svg
- File:HorizontalSeats.svg
- File:Initial composition of the Iowa Senate for the 85th General Assembly.svg
- File:Kätzchen (inflorescence).svg
- File:Matsura mitu Hosi (No background and Black color drawing).svg
- File:Mitu Hosi (No background and Black color drawing).svg
- File:National Assembly of People's Power Cuba.svg
- File:Traube (inflorescence).svg
- File:Wappen Friedensdorf.svg