public class OpenPatricianSliderSkin extends javafx.scene.control.SkinBase<OpenPatricianSlider>
| Modifier and Type | Class and Description |
|---|---|
private class |
OpenPatricianSliderSkin.SteeringWheelGroup
Class encapsulating the steering wheel image.
|
| Modifier and Type | Field and Description |
|---|---|
private List<Double> |
angles |
private OpenPatricianSlider |
control |
(package private) javafx.beans.property.DoubleProperty |
currentRotation |
static int |
INITIAL_ROTATION |
private TextSizingUtility |
sizeing |
private int |
yTranslation |
| Constructor and Description |
|---|
OpenPatricianSliderSkin(OpenPatricianSlider slider) |
| Modifier and Type | Method and Description |
|---|---|
(package private) double |
angleBetween2Lines(javafx.geometry.Point2D center,
javafx.geometry.Point2D point)
Calculate the angle between the vector horizontally to the left from the center
and the current point.
|
(package private) javafx.geometry.Point2D |
calculateBasePoint(javafx.geometry.Point2D center,
double radius,
double angle)
Calculate the base point for the label.
|
(package private) double |
calculateMoveFactor(double angle)
Calculate the factor a label has to be moved based on the position on the curve.
|
(package private) double |
calculateSlope(javafx.geometry.Point2D center,
javafx.geometry.Point2D point)
Caluculate the slope of the line defined by two points.
|
private void |
createAndAddLabels(javafx.scene.Group g,
javafx.geometry.Point2D centerPoint)
Create the labels and add them to the group.
|
(package private) void |
snapToNearestAngle()
Snap to the correct angle.
|
computeBaselineOffset, computeMaxHeight, computeMaxWidth, computeMinHeight, computeMinWidth, computePrefHeight, computePrefWidth, consumeMouseEvents, dispose, executeAccessibleAction, getChildren, getClassCssMetaData, getCssMetaData, getNode, getSkinnable, layoutChildren, layoutInArea, layoutInArea, layoutInArea, positionInArea, positionInArea, pseudoClassStateChanged, queryAccessibleAttribute, snappedBottomInset, snappedLeftInset, snappedRightInset, snappedTopInset, snapPosition, snapSize, snapSpacepublic static final int INITIAL_ROTATION
javafx.beans.property.DoubleProperty currentRotation
private TextSizingUtility sizeing
private final int yTranslation
private final OpenPatricianSlider control
public OpenPatricianSliderSkin(OpenPatricianSlider slider)
private void createAndAddLabels(javafx.scene.Group g,
javafx.geometry.Point2D centerPoint)
g - group the labels are added tocenterPoint - central point around which the labels are placed.void snapToNearestAngle()
double angleBetween2Lines(javafx.geometry.Point2D center,
javafx.geometry.Point2D point)
center - pointpoint - current pointdouble calculateSlope(javafx.geometry.Point2D center,
javafx.geometry.Point2D point)
center - pointpoint - on the circledouble calculateMoveFactor(double angle)
angle - in degree in the range [0,180]javafx.geometry.Point2D calculateBasePoint(javafx.geometry.Point2D center,
double radius,
double angle)
center - point of the circleradius - radius of the circleangle - in degree in [0,180]Copyright © 2011-2017 Sahits GmbH. All Rights Reserved.