JavaFX: Bringing Rich Experiences To All the Screens Of Your Life

Profile: desktop, common

Overview

The Arrow class defines an arrow shape.

the code:

import org.jfxtras.scene.shape.Arrow;
 import javafx.scene.paint.*;

    Arrow {
        x: 10
        y: 10
        width: 100
        height: 60
        rise: 0.5
        depth: 0.5
        fill: Color.BLACK
    }

produces:

Variable Summary

accessnametypeCan ReadCan InitCan WriteDefault Valuedescription
publicangleNumber0

Defines the angle of the arrow in degrees.

Defines the angle of the arrow in degrees. 0 degress is pointing right, 90 degress is straight up, 180 degress is pointing left, and 270 degrees is down.

0  
publicdepthNumber0.5

Defines how far along the shaft the arrowhead starts.

Defines how far along the shaft the arrowhead starts. The range is from 0.0 to 1.0. A value of 0.0 will create a shape that is all arrow head. A value of 0.5 means the arrow will be half shaft and half arrow head. A value of 1.0 will lead to an arrow that is all shaft - basically a rectangle.

0.5  
publicheightNumber60

Defines the height of the arrow.

publicriseNumber0.5

Defines how tall the shaft is compared to the arrowhead.

Defines how tall the shaft is compared to the arrowhead. The range is from 0.0 to 1.0. A value of 0.5 will create an arrow with a shaft that is half of the total height of the arrow. The remaining half of the arrow's height will be divided between the bottom and top edge of the arrow.

0.5  
publicwidthNumber100

Defines the width of the arrow.

publicxNumber0

Defines the X coordinate of the upper-left corner of the base of the arrow.

publicyNumber0

Defines the Y coordinate of the upper-left corner of the base of the arrow.

Inherited Variables

Inherited Functions