Class ArrowPaintHelper
- java.lang.Object
-
- org.openstreetmap.josm.data.osm.visitor.paint.ArrowPaintHelper
-
public class ArrowPaintHelper extends java.lang.Object
This class helps with painting arrows with fixed length along a path.- Since:
- 10827
-
-
Constructor Summary
Constructors Constructor Description ArrowPaintHelper(double radians, double length)
Creates a new arrow helper.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description double
getOnLineLength()
Gets the length of the arrow along the line segment.void
paintArrowAt(MapPath2D path, MapViewState.MapViewPoint point, MapViewState.MapViewPoint fromDirection)
Paint the arrow
-
-
-
Constructor Detail
-
ArrowPaintHelper
public ArrowPaintHelper(double radians, double length)
Creates a new arrow helper.- Parameters:
radians
- The angle of the arrow. 0 means that it lies on the current line. In radianslength
- The length of the arrow lines.
-
-
Method Detail
-
paintArrowAt
public void paintArrowAt(MapPath2D path, MapViewState.MapViewPoint point, MapViewState.MapViewPoint fromDirection)
Paint the arrow- Parameters:
path
- The path to append the arrow to.point
- The point to paint the tip atfromDirection
- The direction the line is coming from.
-
getOnLineLength
public double getOnLineLength()
Gets the length of the arrow along the line segment.- Returns:
- the length along the line
- Since:
- 12154
-
-