Ejemplo n.º 1
0
    private void buildSegments(Border border, Jig jig, AffineTransform at) {
      segments = new ArrayList<PathSegment>();
      double[] coords = new double[6];

      PathIterator topIterator = jig.getTopLine().getPathIterator(at);
      topIterator.currentSegment(coords);
      MovePathSegment start = new MovePathSegment(coords);
      segments.add(start);
      topIterator.next();
      topIterator.currentSegment(coords);
      segments.add(new LinePathSegment(coords));

      if (border.topRightRadius > 0) addArc(at, segments, coords, jig.getTopRightArc());
      addLine(at, segments, coords, jig.getRightLine());
      if (border.bottomRightRadius > 0) addArc(at, segments, coords, jig.getBottomRightArc());
      addLine(at, segments, coords, jig.getBottomLine());
      if (border.bottomLeftRadius > 0) addArc(at, segments, coords, jig.getBottomLeftArc());
      addLine(at, segments, coords, jig.getLeftLine());
      if (border.topLeftRadius > 0) addArc(at, segments, coords, jig.getTopLeftArc());

      start.dump(coords);
      segments.add(new LinePathSegment(coords));
    }
Ejemplo n.º 2
0
 public Arc2D getTopLeftArc() {
   return jig.getTopLeftArc();
 }
Ejemplo n.º 3
0
 public Arc2D getBottomRightArc() {
   return jig.getBottomRightArc();
 }
Ejemplo n.º 4
0
 public Arc2D getBottomLeftArc() {
   return jig.getBottomLeftArc();
 }
Ejemplo n.º 5
0
 public Arc2D getTopRightArc() {
   return jig.getTopRightArc();
 }
Ejemplo n.º 6
0
 public Line2D getLeftLine() {
   return jig.getLeftLine();
 }
Ejemplo n.º 7
0
 public Line2D getBottomLine() {
   return jig.getBottomLine();
 }
Ejemplo n.º 8
0
 public Line2D getRightLine() {
   return jig.getRightLine();
 }
Ejemplo n.º 9
0
 public Line2D getTopLine() {
   return jig.getTopLine();
 }