
// 在坐标(10,50)创建宽320,高200的画布
var
paper = Raphael(10, 50, 320, 200);
// 在坐标(x = 50, y = 40)绘制半径为 10 的圆
var
circle = paper.circle(50, 40, 10);
// 给绘制的圆圈填充红色 (#f00)
circle.attr(
"fill"
,
"#f00"
);
// 设置画笔(stroke)的颜色为白色
circle.attr(
"stroke"
,
"#fff"
);
//高600 宽600 直角坐标系
paper
.path("M0 0 V600,H600");
//M = moveto 参数:(x y) // 移动到
//L = lineto 参数:(x y) //直线
//H = horizontal lineto 参数:(x) //水平
//V = vertical lineto 参数:(y) //垂直
//C = curveto 参数:(x1 y1 x2 y2 x y) //弧线
//S = smooth curveto 参数:(x2 y2 x y) //光滑的弧线
//Q = quadratic Belzier curve 参数:(x1 y1 x y) //二次贝塞尔曲线曲线
//T = smooth quadratic Belzier curveto 参数:(x y) //光滑二次贝塞尔曲线曲线
//A = elliptical Arc 参数:(rx ry x-axis-rotation large-arc-flag sweep-flag x y) //椭圆弧
//Z = closepath 参数(none) //闭合