Class PaintLine


  • public final class PaintLine
    extends java.lang.Object
    Paint a line as a Path2D.Double

    Copyright (c) 2013-2020 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
    BSD-style license. See OpenTrafficSim License.

    $LastChangedDate: 2016-01-15 09:03:55 +0100 (Fri, 15 Jan 2016) $, @version $Revision: 1698 $, by $Author: averbraeck $, initial version 10 apr. 2015

    Author:
    Peter Knoppers
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static OTSPoint3D NEWPATH
      Dummy coordinate that forces the drawing operation to start a new path.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void paintLine​(java.awt.Graphics2D graphics, java.awt.Color color, double width, DirectedPoint referencePoint, OTSLine3D line)
      Paint line.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • NEWPATH

        public static final OTSPoint3D NEWPATH
        Dummy coordinate that forces the drawing operation to start a new path.
    • Method Detail

      • paintLine

        public static void paintLine​(java.awt.Graphics2D graphics,
                                     java.awt.Color color,
                                     double width,
                                     DirectedPoint referencePoint,
                                     OTSLine3D line)
        Paint line.
        Parameters:
        graphics - Graphics2D; the graphics environment
        color - Color; the color to use
        width - double; the width to use
        referencePoint - DirectedPoint; the reference point
        line - OTSLine3D; array of points