Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想画一个直径为奇数(7px)的圆,所以我可以画一条 1px 的直线穿过圆心。
<svg width="600" height="600"> <circle cx="30" cy="30" r="3.5" fill="red" /> </svg>
奇怪的是,无论r值是多少,直径总是均匀的。
r
移动cx和cy坐标.5:
cx
cy
.5
<svg width="600" height="600"> <circle cx="30.5" cy="30.5" r="3.5" fill="red" /> </svg>