示例#1
0
 public void paint(Graphics g) {
   Polygon pt = at.transform(p);
   g.translate(xtranslate, ytranslate);
   g.drawPolygon(pt);
   for (int i = 0; i < pt.npoints; i++) g.drawString("p" + i, pt.xpoints[i], pt.ypoints[i]);
   Rectangle r = pt.getBounds();
   g.drawString("h=" + r.height + " w=" + r.width, r.height / 2, r.width / 2);
 }
示例#2
0
 public Polygon getPolygon() {
   return at.transform(p);
 }
示例#3
0
 public void apply() {
   p = at.transform(p);
   xf.xform(at);
 }