Skip to content

LineArrowNode

Overview

An arrow that is composed of 3 line segments: one for the tail, and 2 for a V-shaped head

@author Chris Malley (PixelZoom, Inc.)

Class LineArrowNode

import { LineArrowNode } from 'scenerystack/scenery-phet';

Constructor

new LineArrowNode( tailX : number, tailY : number, tipX : number, tipY : number, providedOptions? : LineArrowNodeOptions )

Instance Methods

setTailAndTip( tailX : number, tailY : number, tipX : number, tipY : number )

Set the tail and tip positions to update the arrow shape.

Type LineArrowNodeOptions

import type { LineArrowNodeOptions } from 'scenerystack/scenery-phet';
  • stroke?: TColor
    head & tail
  • lineJoin?: LineJoin
  • lineCap?: LineCap
  • headHeight?: number
    head
  • headWidth?: number
  • headLineWidth?: number
  • tailLineWidth?: number
    tail
  • tailLineDash?: number[]
  • & StrictOmit<NodeOptions, "children">

Source Code

See the source for LineArrowNode.ts in the scenery-phet repository.