0

如果我在一个圆圈上使用一个非常小的 stroke-dasharray,它会在圆圈的中间产生奇怪的“类似矩形”的形状。是什么导致了这种行为,有没有办法解决它?

Chrome stroke-dasharray:0.6 及更低版本失败 Firefox stroke-dasharray:2 及更低版本失败

<svg viewBox="0 0 100 100" style="width:800px;height:800px;">
  <circle cx="50" cy="50" r="50" fill="black" stroke="red" stroke-width="100" stroke-dasharray="0.6, 10000"></circle>
</svg>

<svg viewBox="0 0 100 100" style="width:800px;height:800px;">
  <circle cx="50" cy="50" r="50" fill="black" stroke="red" stroke-width="100" stroke-dasharray="0.7, 10000"></circle>
</svg>

<svg viewBox="0 0 100 100" style="width:800px;height:800px;">
  <circle cx="50" cy="50" r="50" fill="black" stroke="red" stroke-width="100" stroke-dasharray="2, 10000"></circle>
</svg>

<svg viewBox="0 0 100 100" style="width:800px;height:800px;">
  <circle cx="50" cy="50" r="50" fill="black" stroke="red" stroke-width="100" stroke-dasharray="3, 10000"></circle>
</svg>

在此处输入图像描述

4

0 回答 0