Y
- type of Y valuespublic class XValueIndicator<Y> extends AbstractSingleValueIndicator<Number,Y>
text
label
describing the value.
Style Classes (from least to most specific):
value-indicator-label, x-value-indicator-label, x-value-indicator-label[index]
value-indicator-line, x-value-indicator-line, x-value-indicator-line[index]
[index]
corresponds to the index (zero based) of this indicator instance added to the
XYChartPane
. For example class x-value-indicator-label1
can be used to style label of the second
instance of this indicator added to the chart pane.labelPositionProperty, valueProperty
labelHorizontalAnchorProperty, labelVerticalAnchorProperty, textProperty
chartPaneProperty
line
label
Constructor and Description |
---|
XValueIndicator(double value)
Creates a new instance of the indicator.
|
XValueIndicator(double value,
String text)
Creates a new instance of the indicator.
|
Modifier and Type | Method and Description |
---|---|
protected ValueAxis<?> |
getValueAxis(XYChartPane<Number,Y> chartPane)
Returns the ValueAxis that this indicator is associated with.
|
void |
layoutChildren()
Optional method that allows the plug-in to react in case the size of the
XYChartPane that it belongs to
has changed. |
getLabelPosition, getValue, labelPositionProperty, layoutLine, setLabelPosition, setValue, valueProperty
getLabelHorizontalAnchor, getLabelVerticalAnchor, getText, labelHorizontalAnchorProperty, labelVerticalAnchorProperty, layoutLabel, setLabelHorizontalAnchor, setLabelVerticalAnchor, setText, textProperty
chartPaneProperty, getChartChildren, getChartPane, getCharts, getLocationInPlotArea, registerMouseEventHandler, setChartPane, toDataPoint, toDisplayPoint
public XValueIndicator(double value)
value
- a X value to be indicatedpublic XValueIndicator(double value, String text)
value
- a X value to be indicatedtext
- the text to be shown by the label. Value of AbstractValueIndicator.textProperty()
.public void layoutChildren()
XYChartPlugin
XYChartPane
that it belongs to
has changed.layoutChildren
in class XYChartPlugin<Number,Y>
protected ValueAxis<?> getValueAxis(XYChartPane<Number,Y> chartPane)
AbstractValueIndicator
getValueAxis
in class AbstractValueIndicator<Number,Y>
chartPane
- chart pane containing the associated axisCopyright © 2019 CERN. All rights reserved.