1
var view = Raphael(10, 50, 800, 600); 
var testLine = view.path("M343,56 L343,560 Z");  // A simple straight line.
testLine.attr({stroke:"gold"}); 
testLine.attr({"stroke-width":25.0});
testLine.attr({"stroke-linecap":"round"});  // No linecap!

为什么 linecap 不设置为圆形?

4

1 回答 1

1

通过删除“Z”路径终止符修复:

var testLine = view.path("M343,56 L343,560");
于 2012-07-02T00:52:50.937 回答