Changeset 5545
- Timestamp:
- 07/22/08 14:00:27 (3 months ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
trunk/SRC/org/openmicroscopy/shoola/util/roi/figures/MeasureBezierFigure.java
r5544 r5545 34 34 import java.text.NumberFormat; 35 35 import java.util.ArrayList; 36 import java.util.HashMap; 37 import java.util.HashSet; 36 38 import java.util.Iterator; 37 39 import java.util.LinkedHashMap; … … 40 42 41 43 //Application-internal dependencies 44 import org.jhotdraw.draw.AttributeKey; 45 import org.jhotdraw.draw.BezierFigure; 46 import org.jhotdraw.geom.BezierPath; 42 47 import org.openmicroscopy.shoola.util.math.geom2D.PlanePoint2D; 43 48 import org.openmicroscopy.shoola.util.roi.model.annotation.AnnotationKeys; … … 94 99 public MeasureBezierFigure() 95 100 { 96 super("Text" );101 super("Text",false); 97 102 c = true; 98 103 shape = null; … … 122 127 public MeasureBezierFigure(String text) 123 128 { 124 super(text, true);129 super(text, false); 125 130 c = true; 126 131 pointArrayX = new ArrayList<Double>(); … … 176 181 bounds = g.getFontMetrics().getStringBounds(polygonLength, g); 177 182 178 if( getPointCount() > 1)183 if(super.getNodeCount() > 1) 179 184 { 180 int midPoint = this.get PointCount()/2-1;185 int midPoint = this.getNodeCount()/2-1; 181 186 if(midPoint<0) 182 187 midPoint = 0; … … 394 399 for (int i = 0 ; i < path.size(); i++) 395 400 { 396 pointArrayX.add(path.get(i).getControlPoint(0).getX());397 401 pointArrayY.add(path.get(i).getControlPoint(0).getY()); 398 402 } 399 403 AnnotationKeys.POINTARRAYX.set(shape, pointArrayX); 400 404 AnnotationKeys.POINTARRAYY.set(shape, pointArrayY); 401 if ( isClosed())405 if (super.isClosed()) 402 406 { 403 407 AnnotationKeys.AREA.set(shape,getArea()); … … 420 424 } 421 425 426 public MeasureBezierFigure clone() 427 { 428 429 MeasureBezierFigure that = (MeasureBezierFigure)super.clone(); 430 return that; 431 } 432 422 433 /** 423 434 * Implemented as specified by the {@link ROIFigure} interface.
