Java Reference
In-Depth Information
Figure 14-5
.
Creating shapes
How It Works
In this solution, you generated some basic 2D shapes. The first shape is a
javafx.scene.shape.CubicCurve
class, which allows you to construct a cu-
bic curve (a “squiggly line”) effect. To create a cubic curve, simply look for the appro-
priate constructor to be instantiated. The following code snippet is used to create a
javafx.scene.shape.CubicCurve
instance:
CubicCurve cubicCurve = new CubicCurve();
cubicCurve.setStartX(50);