Package java.awt.geom

Examples of java.awt.geom.GeneralPath.moveTo()


                mergeAreas(shape, areas, nAreas);
                nAreas = 0; // Start fresh...

                // Then just add box (add the previous char box if first pts)
                if (i==2) {
                    gp.moveTo(boxes[0].x, boxes[0].y);
                    gp.lineTo(boxes[1].x, boxes[1].y);
                    gp.lineTo(boxes[2].x, boxes[2].y);
                    gp.lineTo(boxes[3].x, boxes[3].y);
                    gp.closePath();
                    shape.append(gp, false);
View Full Code Here


                    gp.lineTo(boxes[3].x, boxes[3].y);
                    gp.closePath();
                    shape.append(gp, false);
                    gp.reset();
                }
                gp.moveTo(boxes[4].x, boxes[4].y);
                gp.lineTo(boxes[5].x, boxes[5].y);
                gp.lineTo(boxes[6].x, boxes[6].y);
                gp.lineTo(boxes[7].x, boxes[7].y);
                gp.closePath();
            }
View Full Code Here

                            float _startX, _startY;
                            _startX = (float)( scaleX * ( vpX + mr.ElementAt( 1 ).intValue()));
                            _startY = (float)( scaleY * ( vpY + mr.ElementAt( 2 ).intValue()));

                            GeneralPath gp = new GeneralPath( GeneralPath.WIND_NON_ZERO );
                            gp.moveTo( _startX, _startY );

                            for ( int j = 0; j < bezierCount; j++ ) {
                                cp1X = (float)( scaleX * ( vpX + mr.ElementAt( j*6+3 ).intValue()));
                                cp1Y = (float)( scaleY * ( vpY + mr.ElementAt( j*6+4 ).intValue()));

View Full Code Here

                float y1 = (float)(y0+fullBounds.getHeight());
                // Build the bounds rect the way things expect to see it...
                if (flippedH[i]) {
                    if (flippedV[i]) {
                        GeneralPath gp = new GeneralPath();
                        gp.moveTo(x1,y1);
                        gp.lineTo(x0,y1);
                        gp.lineTo(x0,y0);
                        gp.lineTo(x1,y0);
                        gp.lineTo(x1,y1);
                        gp.closePath();
View Full Code Here

                        gp.lineTo(x1,y1);
                        gp.closePath();
                        tempLogicalBounds[i] = gp;
                    } else {
                        GeneralPath gp = new GeneralPath();
                        gp.moveTo(x1,y0);
                        gp.lineTo(x0,y0);
                        gp.lineTo(x0,y1);
                        gp.lineTo(x1,y1);
                        gp.lineTo(x1,y0);
                        gp.closePath();
View Full Code Here

                        tempLogicalBounds[i] = gp;
                    }
                } else {
                    if (flippedV[i]) {
                        GeneralPath gp = new GeneralPath();
                        gp.moveTo(x0,y1);
                        gp.lineTo(x1,y1);
                        gp.lineTo(x1,y0);
                        gp.lineTo(x0,y0);
                        gp.lineTo(x0,y1);
                        gp.closePath();
View Full Code Here

                float y1 = (float)(y0+height);
                // Build the rect the way things expect to see it...
                if (flippedH[i]) {
                    if (flippedV[i]) {
                        GeneralPath gp = new GeneralPath();
                        gp.moveTo(x1,y1);
                        gp.lineTo(x0,y1);
                        gp.lineTo(x0,y0);
                        gp.lineTo(x1,y0);
                        gp.lineTo(x1,y1);
                        gp.closePath();
View Full Code Here

                        gp.lineTo(x1,y1);
                        gp.closePath();
                        tempLogicalBounds[i] = gp;
                    } else {
                        GeneralPath gp = new GeneralPath();
                        gp.moveTo(x1,y0);
                        gp.lineTo(x0,y0);
                        gp.lineTo(x0,y1);
                        gp.lineTo(x1,y1);
                        gp.lineTo(x1,y0);
                        gp.closePath();
View Full Code Here

                        tempLogicalBounds[i] = gp;
                    }
                } else {
                    if (flippedV[i]) {
                        GeneralPath gp = new GeneralPath();
                        gp.moveTo(x0,y1);
                        gp.lineTo(x1,y1);
                        gp.lineTo(x1,y0);
                        gp.lineTo(x0,y0);
                        gp.lineTo(x0,y1);
                        gp.closePath();
View Full Code Here

     */
    public void drawPolyline(int[] xPoints, int[] yPoints,
                             int nPoints){
        if(nPoints > 0){
            GeneralPath path = new GeneralPath();
            path.moveTo(xPoints[0], yPoints[0]);
            for(int i=1; i<nPoints; i++)
                path.lineTo(xPoints[i], yPoints[i]);

            draw(path);
        }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.