Package java.awt.geom

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


            }
            else {
                right.moveTo((float) xx1, transStack1);
                right.lineTo((float) xx1, transY1);
                right.lineTo((float) xxRight, transStackRight);
                right.closePath();
            }
        }
        else // handle negative value
            transY1 = (float) rangeAxis.valueToJava2D(y1 + stack1[0], dataArea,
                    edge1);
View Full Code Here


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

                        dataArea, edge1);
                right.moveTo((float) xx1, transStack1);
                right.lineTo((float) xx1, transY1);
                right.lineTo((float) xxRight, transYRight);
                right.lineTo((float) xxRight, transStackRight);
                right.closePath();
            }
        }

        if (pass == 0) {
            final Paint itemPaint = getItemPaint(row, column);
View Full Code Here

    final GeneralPath p0 = new GeneralPath();
    p0.moveTo(0.0f, -s);
    p0.lineTo(s, 0.0f);
    p0.lineTo(0.0f, s);
    p0.lineTo(-s, 0.0f);
    p0.closePath();
    return p0;
  }

  /**
   * Creates a triangle shape that points upwards.
View Full Code Here

  {
    final GeneralPath p0 = new GeneralPath();
    p0.moveTo(0.0f, -s);
    p0.lineTo(s, s);
    p0.lineTo(-s, s);
    p0.closePath();
    return p0;
  }

  /**
   * Creates a triangle shape that points downwards.
View Full Code Here

  {
    final GeneralPath p0 = new GeneralPath();
    p0.moveTo(0.0f, s);
    p0.lineTo(s, -s);
    p0.lineTo(-s, -s);
    p0.closePath();
    return p0;
  }


  /**
 
View Full Code Here

            Area area = new Area(shape);
            GeneralPath path = new GeneralPath();
            path.moveTo(w/3, h-1);
            path.lineTo(w/2, h-1-Y_OFFSET);
            path.lineTo(w*2/3, h-1-Y_OFFSET);
            path.closePath();
            area.add(new Area(path));
            return area;
        }
       
        public Dimension getPreferredSize() {
View Full Code Here

                arrow.moveTo(0, height + 0.5f);
                arrow.lineTo(width / 2.0f, 0);
                arrow.lineTo(width, height + 0.5f);
            }

            arrow.closePath();
            // TODO Use Graphics#fillPolygon() as optimization?
            graphics.fill(arrow);
        }
    }
View Full Code Here

                arrow.moveTo(0, 0);
                arrow.lineTo(width / 2.0f, height + 0.5f);
                arrow.lineTo(width, 0);
            }

            arrow.closePath();
            // TODO Use Graphics#fillPolygon() as optimization?
            graphics.fill(arrow);
        }
    }
View Full Code Here

                System.arraycopy(boxes, 0, chull, 0, 8);
                int npts = makeConvexHull(chull, 8);
                gp.moveTo(chull[0].x, chull[0].y);
                for(int n=1; n<npts; n++)
                    gp.lineTo(chull[n].x, chull[n].y);
                gp.closePath();
            } else {
                // Merge all previous areas
                mergeAreas(shape, areas, nAreas);
                nAreas = 0; // Start fresh...
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.