Class OutlineFootprint
java.lang.Object
org.opensourcephysics.cabrillo.tracker.LineFootprint
org.opensourcephysics.cabrillo.tracker.OutlineFootprint
An OutlineFootprint returns an outline shape for a Point array of length 2.
- Author:
- Douglas Brown
-
Field Summary
Fields inherited from class org.opensourcephysics.cabrillo.tracker.LineFootprint
baseStroke, color, DASHED_LINE, DOTTED_LINE, highlight, hitLine, hitShapes, line, name, path, rotatorStroke, stroke, transform, WIDE_DOTTED_LINE
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetIcon
(int w, int h) Gets the icon.org.opensourcephysics.cabrillo.tracker.MultiShape
Gets the draw shape of this footprint.int
Gets the spread.void
setSpread
(int spread) Sets the spread.void
setStroke
(BasicStroke stroke) Overrides LineProfile setStroke method.Methods inherited from class org.opensourcephysics.cabrillo.tracker.LineFootprint
checkStrokes, getColor, getDisplayName, getFootprint, getFootprint, getHighlightShape, getHitShapes, getLength, getMark, getName, getRotatorShape, getStroke, setColor, setDashArray, setLineWidth
-
Constructor Details
-
OutlineFootprint
Constructs an OutlineFootprint.- Parameters:
name
- the name of the footprint
-
-
Method Details
-
setSpread
public void setSpread(int spread) Sets the spread. The width of the outline is (1 + 2*spread).- Parameters:
spread
- the desired spread
-
getSpread
public int getSpread()Gets the spread.- Returns:
- the spread
-
getIcon
Gets the icon.- Specified by:
getIcon
in interfaceFootprint
- Overrides:
getIcon
in classLineFootprint
- Parameters:
w
- width of the iconh
- height of the icon- Returns:
- the icon
-
setStroke
Overrides LineProfile setStroke method.- Specified by:
setStroke
in interfaceFootprint
- Overrides:
setStroke
in classLineFootprint
- Parameters:
stroke
- the desired stroke
-
getShape
Gets the draw shape of this footprint.- Specified by:
getShape
in interfaceFootprint
- Overrides:
getShape
in classLineFootprint
- Parameters:
points
- an array of Pointsscale
- an integer magnification- Returns:
- the draw shape
-