Lines Matching refs:points

379 	// Check to see if we are dragging any of control points.
384 var pts = selectobj[n].points;
390 // control points. Written as a local function to clarify logic.
394 // Check control points for only the "path" shapes.
430 // Check for existing control points
431 // Select only the control points around the selected vertex
563 for(var i = 0; i < obj.points.length; i++){
564 var pt = obj.points[i];
567 // Move control points, too
593 for(var i = 0; i < obj.points.length; i++){
594 var pt = obj.points[i];
596 // Scale control points, too
608 // Scale control points, too
662 if(pointMovingIdx + idx < 0 || pointMoving.points.length <= pointMovingIdx + idx)
664 var p1 = pointMoving.points[pointMovingIdx + idx];
670 // When moving a vertex, Bezier control points associated with that vertex
672 // to the control points later.
673 var dx = mx - pointMoving.points[pointMovingIdx].x;
674 var dy = my - pointMoving.points[pointMovingIdx].y;
675 pointMoving.points[pointMovingIdx].x = mx;
676 pointMoving.points[pointMovingIdx].y = my;
678 if(pointMovingIdx + 1 < pointMoving.points.length)
683 var curpoint = pointMoving.points[pointMovingIdx];
689 // and its vertex is tangent to the curve, so keeping the control points parallel
695 // control points from the central vertex. So we keep using "C" command.
698 if(!e.altKey && pointMovingCP === "d" && pointMovingIdx + 1 < pointMoving.points.length){
699 var nextpoint = pointMoving.points[pointMovingIdx + 1];
711 var prevpoint = pointMoving.points[pointMovingIdx - 1];
813 var numPoints = tool.points;
817 if(numPoints <= obj.points.length)
934 // When pathedit tool is selected, draw handles on the shape's control points
935 // and the path that connecting control points, but not the
939 var pts = shape.points;
972 // Handles and guiding lines for the control points
989 this.points = [];
1001 for (var i=0; i<this.points.length; i++){
1003 // Prepend control points if this vertex has them.
1004 if("cx" in this.points[i] && "cy" in this.points[i])
1005 dat += this.points[i].cx+","+this.points[i].cy+",";
1006 if("dx" in this.points[i] && "dy" in this.points[i])
1007 dat += this.points[i].dx+","+this.points[i].dy+",";
1008 dat += this.points[i].x+","+this.points[i].y;
1012 points: dat
1028 if("points" in obj){
1029 var pt1 = obj.points.split(":");
1046 this.points = arr;
1053 for(var j = 0; j < this.points.length; j++){
1054 var x = this.points[j].x;
1059 var y = this.points[j].y;
1082 return {minx: this.points[0].x, miny: this.points[0].y,
1083 maxx: this.points[0].x + width, maxy: this.points[0].y + height};
1118 return {minx: this.points[0].x, miny: this.points[0].y - height,
1119 maxx: this.points[0].x + width, maxy: this.points[0].y};
1142 for (var i=0; i<this.points.length; i++){
1143 var pt = this.points[i];
1146 // Prepend control points if this vertex has them.
1150 src += this.points[i-1].x+","+this.points[i-1].y+" ";
1164 delete alldat.points;
1208 this.points = arr;
1806 /// @param points Number of points which are used to describe points
1813 function Tool(name, points, params){
1815 this.points = points || 1;
1844 if (cur_shape.points.length === cur_tool.points){
1853 cur_shape.points.push(canvasToSrc(constrainCoord({x:x, y:y})));
1864 // Add two points for previewing shapes that consist of multiple points,
1879 if(cur_shape && 0 < cur_shape.points.length){
1885 cur_shape.points[cur_shape.points.length-1] = canvasToSrc(constrainCoord(coord));
1994 if(this.selectPointShape.points.length <= 2){
1999 this.selectPointShape.points.splice(this.selectPointIdx, 1);
2018 var arr = obj.points;
2033 var arr = obj.points;
2046 var arr = obj.points;
2066 var arr = obj.points;
2082 var arr = obj.points;
2100 var arr = obj.points;
2122 var arr = obj.points;
2143 var arr = obj.points;
2160 var arr = obj.points;
2176 var arr = obj.points;
2193 var arr = obj.points;
2212 var arr = obj.points;
2230 var arr = obj.points;
2252 ctx.fillText(str, obj.points[0].x, obj.points[0].y);
2258 ctx.moveTo(obj.points[0].x, obj.points[0].y + 4);
2259 ctx.lineTo(obj.points[0].x + ctx.measureText(str).width, obj.points[0].y + 4);
2328 obj.points.push({x: lay.canvasPos.x, y: lay.canvasPos.y});
2417 var arr = obj.points;
2432 var arr = obj.points;
2500 var pts = cur_shape.points;
2516 var pts = cur_shape.points;
2520 cur_shape.points.pop();
2549 this.lastPoint = cur_shape.points[cur_shape.points.length-1];
2561 if(0 < cur_shape.points.length && (pt.x !== d.x && pt.y !== d.y)){
2562 var prev = cur_shape.points[cur_shape.points.length-2];
2569 else if(0 < cur_shape.points.length){
2572 var pt = cur_shape.points[cur_shape.points.length-1];