Package java.awt.geom

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


                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

                        coords[count++] = (float)t.nval;
                        if (count == pointCount[type]) {
                            count = 0;
                            switch(type) {
                            case java.awt.geom.PathIterator.SEG_MOVETO:
                                s.moveTo(coords[0], coords[1]);
                                break;
                            case java.awt.geom.PathIterator.SEG_LINETO:
                                s.lineTo(coords[0], coords[1]);
                                break;
                            case java.awt.geom.PathIterator.SEG_QUADTO:
View Full Code Here

        for (int i=0; i<sides; i++) {
            angle    = (i)*(2*Math.PI/sides) - (Math.PI/2);
            x = cx + ir*Math.cos(angle);
            y = cy - ir*Math.sin(angle);
            if (i==0)
                gp.moveTo((float)x, (float)y);
            else
                gp.lineTo((float)x, (float)y);

            angle    = (i+0.5)*(2*Math.PI/sides) - (Math.PI/2);
            x = cx + r*Math.cos(angle);
 
View Full Code Here

      {
        case PathIterator.SEG_MOVETO:
          {
            final float x = in.readFloat();
            final float y = in.readFloat();
            gp.moveTo(x, y);
            break;
          }
        case PathIterator.SEG_LINETO:
          {
            final float x = in.readFloat();
View Full Code Here

          path.lineTo(segments[i].getX1(), segments[i].getY1());
          break;
        }
        case PathIterator.SEG_MOVETO:
        {
          path.moveTo(segments[i].getX1(), segments[i].getY1());
          break;
        }
        case PathIterator.SEG_QUADTO:
        {
          path.quadTo(segments[i].getX1(), segments[i].getY1(),
View Full Code Here

            // RIGHT POLYGON
            if (y2 >= 0.0) {
                final double yright = (y1 + y2) / 2.0 + stackRight[1];
                final float transYRight
                    = (float) rangeAxis.valueToJava2D(yright, dataArea, edge1);
                right.moveTo((float) xx1, transStack1);
                right.lineTo((float) xx1, transY1);
                right.lineTo((float) xxRight, transYRight);
                right.lineTo((float) xxRight, transStackRight);
                right.closePath();
            }
View Full Code Here

                right.lineTo((float) xxRight, transYRight);
                right.lineTo((float) xxRight, transStackRight);
                right.closePath();
            }
            else {
                right.moveTo((float) xx1, transStack1);
                right.lineTo((float) xx1, transY1);
                right.lineTo((float) xxRight, transStackRight);
                right.closePath();
            }
        }
View Full Code Here

            final float transStackRight = (float) rangeAxis.valueToJava2D(
                    adjStackRight[0], dataArea, edge1);

            // RIGHT POLYGON
            if (y2 >= 0.0) {
                right.moveTo((float) xx1, transStack1);
                right.lineTo((float) xx1, transY1);
                right.lineTo((float) xxRight, transStackRight);
                right.closePath();
            }
            else {
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.