Spec-Zone.ru › OpenJavaFX 17

Class ValueAxis<T extends Number>

java.lang.Object
javafx.scene.Node
javafx.scene.Parent
javafx.scene.layout.Region
javafx.scene.chart.Axis<T>
javafx.scene.chart.ValueAxis<T>
All Implemented Interfaces:
Styleable, EventTarget
Direct Known Subclasses:
NumberAxis
public abstract class ValueAxis<T extends Number>
extends Axis<T>
An axis whose data is defined as Numbers. It can also draw minor tick-marks between the major ones.
Since:
JavaFX 2.0

Property Summary

Properties
Type Property Description
DoubleProperty lowerBound
The value for the lower bound of this axis (minimum value).
IntegerProperty minorTickCount
The number of minor tick divisions to be displayed between each major tick mark.
DoubleProperty minorTickLength
The length of minor tick mark lines.
BooleanProperty minorTickVisible
true if minor tick marks should be displayed
ReadOnlyDoubleProperty scale
The scale factor from data units to visual units
ObjectProperty<StringConverter<T>> tickLabelFormatter
StringConverter used to format tick mark labels.
DoubleProperty upperBound
The value for the upper bound of this axis (maximum value).

Properties declared in class javafx.scene.chart.Axis

animated, autoRanging, label, side, tickLabelFill, tickLabelFont, tickLabelGap, tickLabelRotation, tickLabelsVisible, tickLength, tickMarkVisible

Properties declared in class javafx.scene.layout.Region

background, border, cacheShape, centerShape, height, insets, maxHeight, maxWidth, minHeight, minWidth, opaqueInsets, padding, prefHeight, prefWidth, scaleShape, shape, snapToPixel, width

Properties declared in class javafx.scene.Parent

needsLayout

Properties declared in class javafx.scene.Node

accessibleHelp, accessibleRoleDescription, accessibleRole, accessibleText, blendMode, boundsInLocal, boundsInParent, cacheHint, cache, clip, cursor, depthTest, disabled, disable, effectiveNodeOrientation, effect, eventDispatcher, focused, focusTraversable, hover, id, inputMethodRequests, layoutBounds, layoutX, layoutY, localToParentTransform, localToSceneTransform, managed, mouseTransparent, nodeOrientation, onContextMenuRequested, onDragDetected, onDragDone, onDragDropped, onDragEntered, onDragExited, onDragOver, onInputMethodTextChanged, onKeyPressed, onKeyReleased, onKeyTyped, onMouseClicked, onMouseDragEntered, onMouseDragExited, onMouseDragged, onMouseDragOver, onMouseDragReleased, onMouseEntered, onMouseExited, onMouseMoved, onMousePressed, onMouseReleased, onRotate, onRotationFinished, onRotationStarted, onScrollFinished, onScroll, onScrollStarted, onSwipeDown, onSwipeLeft, onSwipeRight, onSwipeUp, onTouchMoved, onTouchPressed, onTouchReleased, onTouchStationary, onZoomFinished, onZoom, onZoomStarted, opacity, parent, pickOnBounds, pressed, rotate, rotationAxis, scaleX, scaleY, scaleZ, scene, style, translateX, translateY, translateZ, viewOrder, visible

Nested Class Summary

Nested classes/interfaces declared in class javafx.scene.chart.Axis

Axis.TickMark<T>

Field Summary

Fields
Modifier and Type Field Description
protected DoubleProperty currentLowerBound
The current value for the lowerBound of this axis (minimum value).

Fields declared in class javafx.scene.layout.Region

USE_COMPUTED_SIZE, USE_PREF_SIZE

Fields declared in class javafx.scene.Node

BASELINE_OFFSET_SAME_AS_HEIGHT

Constructor Summary

Constructors
Constructor Description
ValueAxis()
Creates a auto-ranging ValueAxis.
ValueAxis​(double lowerBound, double upperBound)
Creates a non-auto-ranging ValueAxis with the given lower and upper bound.

Method Summary

Modifier and Type Method Description
protected Object autoRange​(double length)
This calculates the upper and lower bound based on the data provided to invalidateRange() method.
protected Object autoRange​(double minValue, double maxValue, double length, double labelSize)
Called to set the upper and lower bound and anything else that needs to be auto-ranged.
protected abstract List<T> calculateMinorTickMarks()
Calculates a list of the data values for every minor tick mark
protected double calculateNewScale​(double length, double lowerBound, double upperBound)
Calculates new scale for this axis.
static List<CssMetaData<? extends Styleable,​?>> getClassCssMetaData()
List<CssMetaData<? extends Styleable,​?>> getCssMetaData()
This method should delegate to Node.getClassCssMetaData() so that a Node's CssMetaData can be accessed without the need for reflection.
double getDisplayPosition​(T value)
Gets the display position along this axis for a given value.
double getLowerBound()
Gets the value of the property lowerBound.
int getMinorTickCount()
Gets the value of the property minorTickCount.
double getMinorTickLength()
Gets the value of the property minorTickLength.
double getScale()
Gets the value of the property scale.
StringConverter<T> getTickLabelFormatter()
Gets the value of the property tickLabelFormatter.
double getUpperBound()
Gets the value of the property upperBound.
T getValueForDisplay​(double displayPosition)
Gets the data value for the given display position on this axis.
double getZeroPosition()
Gets the display position of the zero line along this axis.
void invalidateRange​(List<T> data)
Called when the data has changed and the range may not be valid anymore.
boolean isMinorTickVisible()
Gets the value of the property minorTickVisible.
boolean isValueOnAxis​(T value)
Checks if the given value is plottable on this axis
protected void layoutChildren()
Invoked during the layout pass to layout this axis and all its content.
DoubleProperty lowerBoundProperty()
The value for the lower bound of this axis (minimum value).
IntegerProperty minorTickCountProperty()
The number of minor tick divisions to be displayed between each major tick mark.
DoubleProperty minorTickLengthProperty()
The length of minor tick mark lines.
BooleanProperty minorTickVisibleProperty()
true if minor tick marks should be displayed
ReadOnlyDoubleProperty scaleProperty()
The scale factor from data units to visual units
void setLowerBound​(double value)
Sets the value of the property lowerBound.
void setMinorTickCount​(int value)
Sets the value of the property minorTickCount.
void setMinorTickLength​(double value)
Sets the value of the property minorTickLength.
void setMinorTickVisible​(boolean value)
Sets the value of the property minorTickVisible.
protected void setScale​(double scale)
Sets the value of the property scale.
void setTickLabelFormatter​(StringConverter<T> value)
Sets the value of the property tickLabelFormatter.
void setUpperBound​(double value)
Sets the value of the property upperBound.
ObjectProperty<StringConverter<T>> tickLabelFormatterProperty()
StringConverter used to format tick mark labels.
protected void tickMarksUpdated()
Called during layout if the tickmarks have been updated, allowing subclasses to do anything they need to in reaction.
double toNumericValue​(T value)
All axis values must be representable by some numeric value.
T toRealValue​(double value)
All axis values must be representable by some numeric value.
DoubleProperty upperBoundProperty()
The value for the upper bound of this axis (maximum value).

Methods declared in class javafx.scene.chart.Axis

animatedProperty, autoRangingProperty, calculateTickValues, computePrefHeight, computePrefWidth, getAnimated, getLabel, getRange, getSide, getTickLabelFill, getTickLabelFont, getTickLabelGap, getTickLabelRotation, getTickLength, getTickMarkLabel, getTickMarks, invalidateRange, isAutoRanging, isRangeValid, isTickLabelsVisible, isTickMarkVisible, labelProperty, measureTickMarkLabelSize, measureTickMarkSize, measureTickMarkSize, requestAxisLayout, requestLayout, setAnimated, setAutoRanging, setLabel, setRange, setSide, setTickLabelFill, setTickLabelFont, setTickLabelGap, setTickLabelRotation, setTickLabelsVisible, setTickLength, setTickMarkVisible, shouldAnimate, sideProperty, tickLabelFillProperty, tickLabelFontProperty, tickLabelGapProperty, tickLabelRotationProperty, tickLabelsVisibleProperty, tickLengthProperty, tickMarkVisibleProperty

Methods declared in class javafx.scene.layout.Region

backgroundProperty, borderProperty, cacheShapeProperty, centerShapeProperty, computeMaxHeight, computeMaxWidth, computeMinHeight, computeMinWidth, getBackground, getBorder, getHeight, getInsets, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getOpaqueInsets, getPadding, getPrefHeight, getPrefWidth, getShape, getUserAgentStylesheet, getWidth, heightProperty, insetsProperty, isCacheShape, isCenterShape, isResizable, isScaleShape, isSnapToPixel, layoutInArea, layoutInArea, layoutInArea, layoutInArea, maxHeight, maxHeightProperty, maxWidth, maxWidthProperty, minHeight, minHeightProperty, minWidth, minWidthProperty, opaqueInsetsProperty, paddingProperty, positionInArea, positionInArea, prefHeight, prefHeightProperty, prefWidth, prefWidthProperty, resize, scaleShapeProperty, setBackground, setBorder, setCacheShape, setCenterShape, setHeight, setMaxHeight, setMaxSize, setMaxWidth, setMinHeight, setMinSize, setMinWidth, setOpaqueInsets, setPadding, setPrefHeight, setPrefSize, setPrefWidth, setScaleShape, setShape, setSnapToPixel, setWidth, shapeProperty, snappedBottomInset, snappedLeftInset, snappedRightInset, snappedTopInset, snapPosition, snapPositionX, snapPositionY, snapSize, snapSizeX, snapSizeY, snapSpace, snapSpaceX, snapSpaceY, snapToPixelProperty, widthProperty

Methods declared in class javafx.scene.Parent

getBaselineOffset, getChildren, getChildrenUnmodifiable, getManagedChildren, getStylesheets, isNeedsLayout, layout, needsLayoutProperty, requestParentLayout, setNeedsLayout, updateBounds

Methods declared in class javafx.scene.Node

accessibleHelpProperty, accessibleRoleDescriptionProperty, accessibleRoleProperty, accessibleTextProperty, addEventFilter, addEventHandler, applyCss, autosize, blendModeProperty, boundsInLocalProperty, boundsInParentProperty, buildEventDispatchChain, cacheHintProperty, cacheProperty, clipProperty, computeAreaInScreen, contains, contains, cursorProperty, depthTestProperty, disabledProperty, disableProperty, effectiveNodeOrientationProperty, effectProperty, eventDispatcherProperty, executeAccessibleAction, fireEvent, focusedProperty, focusTraversableProperty, getAccessibleHelp, getAccessibleRole, getAccessibleRoleDescription, getAccessibleText, getBlendMode, getBoundsInLocal, getBoundsInParent, getCacheHint, getClip, getContentBias, getCursor, getDepthTest, getEffect, getEffectiveNodeOrientation, getEventDispatcher, getId, getInitialCursor, getInitialFocusTraversable, getInputMethodRequests, getLayoutBounds, getLayoutX, getLayoutY, getLocalToParentTransform, getLocalToSceneTransform, getNodeOrientation, getOnContextMenuRequested, getOnDragDetected, getOnDragDone, getOnDragDropped, getOnDragEntered, getOnDragExited, getOnDragOver, getOnInputMethodTextChanged, getOnKeyPressed, getOnKeyReleased, getOnKeyTyped, getOnMouseClicked, getOnMouseDragEntered, getOnMouseDragExited, getOnMouseDragged, getOnMouseDragOver, getOnMouseDragReleased, getOnMouseEntered, getOnMouseExited, getOnMouseMoved, getOnMousePressed, getOnMouseReleased, getOnRotate, getOnRotationFinished, getOnRotationStarted, getOnScroll, getOnScrollFinished, getOnScrollStarted, getOnSwipeDown, getOnSwipeLeft, getOnSwipeRight, getOnSwipeUp, getOnTouchMoved, getOnTouchPressed, getOnTouchReleased, getOnTouchStationary, getOnZoom, getOnZoomFinished, getOnZoomStarted, getOpacity, getParent, getProperties, getPseudoClassStates, getRotate, getRotationAxis, getScaleX, getScaleY, getScaleZ, getScene, getStyle, getStyleableParent, getTransforms, getTranslateX, getTranslateY, getTranslateZ, getTypeSelector, getUserData, getViewOrder, hasProperties, hoverProperty, idProperty, inputMethodRequestsProperty, intersects, intersects, isCache, isDisable, isDisabled, isFocused, isFocusTraversable, isHover, isManaged, isMouseTransparent, isPickOnBounds, isPressed, isVisible, layoutBoundsProperty, layoutXProperty, layoutYProperty, localToParent, localToParent, localToParent, localToParent, localToParent, localToParentTransformProperty, localToScene, localToScene, localToScene, localToScene, localToScene, localToScene, localToScene, localToScene, localToScene, localToScene, localToSceneTransformProperty, localToScreen, localToScreen, localToScreen, localToScreen, localToScreen, lookup, lookupAll, managedProperty, mouseTransparentProperty, nodeOrientationProperty, notifyAccessibleAttributeChanged, onContextMenuRequestedProperty, onDragDetectedProperty, onDragDoneProperty, onDragDroppedProperty, onDragEnteredProperty, onDragExitedProperty, onDragOverProperty, onInputMethodTextChangedProperty, onKeyPressedProperty, onKeyReleasedProperty, onKeyTypedProperty, onMouseClickedProperty, onMouseDragEnteredProperty, onMouseDragExitedProperty, onMouseDraggedProperty, onMouseDragOverProperty, onMouseDragReleasedProperty, onMouseEnteredProperty, onMouseExitedProperty, onMouseMovedProperty, onMousePressedProperty, onMouseReleasedProperty, onRotateProperty, onRotationFinishedProperty, onRotationStartedProperty, onScrollFinishedProperty, onScrollProperty, onScrollStartedProperty, onSwipeDownProperty, onSwipeLeftProperty, onSwipeRightProperty, onSwipeUpProperty, onTouchMovedProperty, onTouchPressedProperty, onTouchReleasedProperty, onTouchStationaryProperty, onZoomFinishedProperty, onZoomProperty, onZoomStartedProperty, opacityProperty, parentProperty, parentToLocal, parentToLocal, parentToLocal, parentToLocal, parentToLocal, pickOnBoundsProperty, pressedProperty, pseudoClassStateChanged, queryAccessibleAttribute, relocate, removeEventFilter, removeEventHandler, requestFocus, resizeRelocate, rotateProperty, rotationAxisProperty, scaleXProperty, scaleYProperty, scaleZProperty, sceneProperty, sceneToLocal, sceneToLocal, sceneToLocal, sceneToLocal, sceneToLocal, sceneToLocal, sceneToLocal, sceneToLocal, screenToLocal, screenToLocal, screenToLocal, setAccessibleHelp, setAccessibleRole, setAccessibleRoleDescription, setAccessibleText, setBlendMode, setCache, setCacheHint, setClip, setCursor, setDepthTest, setDisable, setDisabled, setEffect, setEventDispatcher, setEventHandler, setFocused, setFocusTraversable, setHover, setId, setInputMethodRequests, setLayoutX, setLayoutY, setManaged, setMouseTransparent, setNodeOrientation, setOnContextMenuRequested, setOnDragDetected, setOnDragDone, setOnDragDropped, setOnDragEntered, setOnDragExited, setOnDragOver, setOnInputMethodTextChanged, setOnKeyPressed, setOnKeyReleased, setOnKeyTyped, setOnMouseClicked, setOnMouseDragEntered, setOnMouseDragExited, setOnMouseDragged, setOnMouseDragOver, setOnMouseDragReleased, setOnMouseEntered, setOnMouseExited, setOnMouseMoved, setOnMousePressed, setOnMouseReleased, setOnRotate, setOnRotationFinished, setOnRotationStarted, setOnScroll, setOnScrollFinished, setOnScrollStarted, setOnSwipeDown, setOnSwipeLeft, setOnSwipeRight, setOnSwipeUp, setOnTouchMoved, setOnTouchPressed, setOnTouchReleased, setOnTouchStationary, setOnZoom, setOnZoomFinished, setOnZoomStarted, setOpacity, setPickOnBounds, setPressed, setRotate, setRotationAxis, setScaleX, setScaleY, setScaleZ, setStyle, setTranslateX, setTranslateY, setTranslateZ, setUserData, setViewOrder, setVisible, snapshot, snapshot, startDragAndDrop, startFullDrag, styleProperty, toBack, toFront, toString, translateXProperty, translateYProperty, translateZProperty, usesMirroring, viewOrderProperty, visibleProperty

Methods declared in class java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

Methods declared in interface javafx.css.Styleable

getStyleableNode, getStyleClass

Property Details

minorTickVisible

public final BooleanProperty minorTickVisibleProperty
true if minor tick marks should be displayed
See Also:
isMinorTickVisible(), setMinorTickVisible(boolean)

scale

public final ReadOnlyDoubleProperty scaleProperty
The scale factor from data units to visual units
See Also:
getScale(), setScale(double)

upperBound

public final DoubleProperty upperBoundProperty
The value for the upper bound of this axis (maximum value). This is automatically set if auto ranging is on.
See Also:
getUpperBound(), setUpperBound(double)

lowerBound

public final DoubleProperty lowerBoundProperty
The value for the lower bound of this axis (minimum value). This is automatically set if auto ranging is on.
See Also:
getLowerBound(), setLowerBound(double)

tickLabelFormatter

public final ObjectProperty<StringConverter<T extends Number>> tickLabelFormatterProperty
StringConverter used to format tick mark labels. If null a default will be used
See Also:
getTickLabelFormatter(), setTickLabelFormatter(StringConverter)

minorTickLength

public final DoubleProperty minorTickLengthProperty
The length of minor tick mark lines. Set to 0 to not display minor tick marks.
See Also:
getMinorTickLength(), setMinorTickLength(double)

minorTickCount

public final IntegerProperty minorTickCountProperty
The number of minor tick divisions to be displayed between each major tick mark. The number of actual minor tick marks will be one less than this.
See Also:
getMinorTickCount(), setMinorTickCount(int)

Field Details

currentLowerBound

protected final DoubleProperty currentLowerBound
The current value for the lowerBound of this axis (minimum value). This may be the same as lowerBound or different. It is used by NumberAxis to animate the lowerBound from the old value to the new value.

Constructor Details

ValueAxis

public ValueAxis()
Creates a auto-ranging ValueAxis.

ValueAxis

public ValueAxis(double lowerBound, double upperBound)
Creates a non-auto-ranging ValueAxis with the given lower and upper bound.
Parameters:
lowerBound - The lower bound for this axis, i.e. min plottable value
upperBound - The upper bound for this axis, i.e. max plottable value

Method Details

isMinorTickVisible

public final boolean isMinorTickVisible()
Gets the value of the property minorTickVisible.
Property description:
true if minor tick marks should be displayed

setMinorTickVisible

public final void setMinorTickVisible(boolean value)
Sets the value of the property minorTickVisible.
Property description:
true if minor tick marks should be displayed

minorTickVisibleProperty

public final BooleanProperty minorTickVisibleProperty()
true if minor tick marks should be displayed
See Also:
isMinorTickVisible(), setMinorTickVisible(boolean)

getScale

public final double getScale()
Gets the value of the property scale.
Property description:
The scale factor from data units to visual units

setScale

protected final void setScale(double scale)
Sets the value of the property scale.
Property description:
The scale factor from data units to visual units

scaleProperty

public final ReadOnlyDoubleProperty scaleProperty()
The scale factor from data units to visual units
See Also:
getScale(), setScale(double)

getUpperBound

public final double getUpperBound()
Gets the value of the property upperBound.
Property description:
The value for the upper bound of this axis (maximum value). This is automatically set if auto ranging is on.

setUpperBound

public final void setUpperBound(double value)
Sets the value of the property upperBound.
Property description:
The value for the upper bound of this axis (maximum value). This is automatically set if auto ranging is on.

upperBoundProperty

public final DoubleProperty upperBoundProperty()
The value for the upper bound of this axis (maximum value). This is automatically set if auto ranging is on.
See Also:
getUpperBound(), setUpperBound(double)

getLowerBound

public final double getLowerBound()
Gets the value of the property lowerBound.
Property description:
The value for the lower bound of this axis (minimum value). This is automatically set if auto ranging is on.

setLowerBound

public final void setLowerBound(double value)
Sets the value of the property lowerBound.
Property description:
The value for the lower bound of this axis (minimum value). This is automatically set if auto ranging is on.

lowerBoundProperty

public final DoubleProperty lowerBoundProperty()
The value for the lower bound of this axis (minimum value). This is automatically set if auto ranging is on.
See Also:
getLowerBound(), setLowerBound(double)

getTickLabelFormatter

public final StringConverter<T> getTickLabelFormatter()
Gets the value of the property tickLabelFormatter.
Property description:
StringConverter used to format tick mark labels. If null a default will be used

setTickLabelFormatter

public final void setTickLabelFormatter(StringConverter<T> value)
Sets the value of the property tickLabelFormatter.
Property description:
StringConverter used to format tick mark labels. If null a default will be used

tickLabelFormatterProperty

public final ObjectProperty<StringConverter<T>> tickLabelFormatterProperty()
StringConverter used to format tick mark labels. If null a default will be used
See Also:
getTickLabelFormatter(), setTickLabelFormatter(StringConverter)

getMinorTickLength

public final double getMinorTickLength()
Gets the value of the property minorTickLength.
Property description:
The length of minor tick mark lines. Set to 0 to not display minor tick marks.

setMinorTickLength

public final void setMinorTickLength(double value)
Sets the value of the property minorTickLength.
Property description:
The length of minor tick mark lines. Set to 0 to not display minor tick marks.

minorTickLengthProperty

public final DoubleProperty minorTickLengthProperty()
The length of minor tick mark lines. Set to 0 to not display minor tick marks.
See Also:
getMinorTickLength(), setMinorTickLength(double)

getMinorTickCount

public final int getMinorTickCount()
Gets the value of the property minorTickCount.
Property description:
The number of minor tick divisions to be displayed between each major tick mark. The number of actual minor tick marks will be one less than this.

setMinorTickCount

public final void setMinorTickCount(int value)
Sets the value of the property minorTickCount.
Property description:
The number of minor tick divisions to be displayed between each major tick mark. The number of actual minor tick marks will be one less than this.

minorTickCountProperty

public final IntegerProperty minorTickCountProperty()
The number of minor tick divisions to be displayed between each major tick mark. The number of actual minor tick marks will be one less than this.
See Also:
getMinorTickCount(), setMinorTickCount(int)

autoRange

protected final Object autoRange(double length)
This calculates the upper and lower bound based on the data provided to invalidateRange() method. This must not affect the state of the axis. Any results of the auto-ranging should be returned in the range object. This will we passed to setRange() if it has been decided to adopt this range for this axis.
Specified by:
autoRange in class Axis<T extends Number>
Parameters:
length - The length of the axis in screen coordinates
Returns:
Range information, this is implementation dependent

calculateNewScale

protected final double calculateNewScale(double length, double lowerBound, double upperBound)
Calculates new scale for this axis. This should not affect any properties of this axis.
Parameters:
length - The display length of the axis
lowerBound - The lower bound value
upperBound - The upper bound value
Returns:
new scale to fit the range from lower bound to upper bound in the given display length

autoRange

protected Object autoRange(double minValue, double maxValue, double length, double labelSize)
Called to set the upper and lower bound and anything else that needs to be auto-ranged. This must not affect the state of the axis. Any results of the auto-ranging should be returned in the range object. This will we passed to setRange() if it has been decided to adopt this range for this axis.
Parameters:
minValue - The min data value that needs to be plotted on this axis
maxValue - The max data value that needs to be plotted on this axis
length - The length of the axis in display coordinates
labelSize - The approximate average size a label takes along the axis
Returns:
The calculated range

calculateMinorTickMarks

protected abstract List<T> calculateMinorTickMarks()
Calculates a list of the data values for every minor tick mark
Returns:
List of data values where to draw minor tick marks

tickMarksUpdated

protected void tickMarksUpdated()
Called during layout if the tickmarks have been updated, allowing subclasses to do anything they need to in reaction.
Overrides:
tickMarksUpdated in class Axis<T extends Number>

layoutChildren

protected void layoutChildren()
Invoked during the layout pass to layout this axis and all its content.
Overrides:
layoutChildren in class Axis<T extends Number>

invalidateRange

public void invalidateRange(List<T> data)
Called when the data has changed and the range may not be valid anymore. This is only called by the chart if isAutoRanging() returns true. If we are auto ranging it will cause layout to be requested and auto ranging to happen on next layout pass.
Overrides:
invalidateRange in class Axis<T extends Number>
Parameters:
data - The current set of all data that needs to be plotted on this axis

getDisplayPosition

public double getDisplayPosition(T value)
Gets the display position along this axis for a given value. If the value is not in the current range, the returned value will be an extrapolation of the display position.
Specified by:
getDisplayPosition in class Axis<T extends Number>
Parameters:
value - The data value to work out display position for
Returns:
display position

getValueForDisplay

public T getValueForDisplay(double displayPosition)
Gets the data value for the given display position on this axis. If the axis is a CategoryAxis this will be the nearest value.
Specified by:
getValueForDisplay in class Axis<T extends Number>
Parameters:
displayPosition - A pixel position on this axis
Returns:
the nearest data value to the given pixel position or null if not on axis;

getZeroPosition

public double getZeroPosition()
Gets the display position of the zero line along this axis.
Specified by:
getZeroPosition in class Axis<T extends Number>
Returns:
display position or Double.NaN if zero is not in current range;

isValueOnAxis

public boolean isValueOnAxis(T value)
Checks if the given value is plottable on this axis
Specified by:
isValueOnAxis in class Axis<T extends Number>
Parameters:
value - The value to check if its on axis
Returns:
true if the given value is plottable on this axis

toNumericValue

public double toNumericValue(T value)
All axis values must be representable by some numeric value. This gets the numeric value for a given data value.
Specified by:
toNumericValue in class Axis<T extends Number>
Parameters:
value - The data value to convert
Returns:
Numeric value for the given data value

toRealValue

public T toRealValue(double value)
All axis values must be representable by some numeric value. This gets the data value for a given numeric value.
Specified by:
toRealValue in class Axis<T extends Number>
Parameters:
value - The numeric value to convert
Returns:
Data value for given numeric value

getClassCssMetaData

public static List<CssMetaData<? extends Styleable,?>> getClassCssMetaData()
Returns:
The CssMetaData associated with this class, which may include the CssMetaData of its superclasses.
Since:
JavaFX 8.0

getCssMetaData

public List<CssMetaData<? extends Styleable,?>> getCssMetaData()
This method should delegate to Node.getClassCssMetaData() so that a Node's CssMetaData can be accessed without the need for reflection.
Specified by:
getCssMetaData in interface Styleable
Overrides:
getCssMetaData in class Axis<T extends Number>
Returns:
The CssMetaData associated with this node, which may include the CssMetaData of its superclasses.
Since:
JavaFX 8.0

© 2008, 2025, Oracle and/or its affiliates. All rights reserved.
Documentation extracted from JavaFX API Documentation.
Licensed under the GNU General Public License, version 2, with the Classpath Exception.
Java, JavaFX and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.

Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API