Class SunburstChart<T extends ChartItem>

java.lang.Object
javafx.scene.Node
javafx.scene.Parent
javafx.scene.layout.Region
eu.hansolo.fx.charts.SunburstChart<T>
All Implemented Interfaces:
javafx.css.Styleable, javafx.event.EventTarget

@DefaultProperty("children") public class SunburstChart<T extends ChartItem> extends javafx.scene.layout.Region
  • Property Summary

    Properties
    Type
    Property
    Description
    javafx.beans.property.BooleanProperty
     
    javafx.beans.property.ObjectProperty<javafx.scene.paint.Color>
     
    javafx.beans.property.ObjectProperty<javafx.scene.paint.Color>
     
    javafx.beans.property.ObjectProperty<javafx.scene.paint.Color>
     
    javafx.beans.property.IntegerProperty
     
    javafx.beans.property.BooleanProperty
     
    javafx.beans.property.ObjectProperty<javafx.scene.paint.Color>
     
    javafx.beans.property.ObjectProperty<TextOrientation>
     
    javafx.beans.property.BooleanProperty
     
    javafx.beans.property.ObjectProperty<VisibleData>
     

    Properties inherited from class javafx.scene.layout.Region

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

    Properties inherited from class javafx.scene.Parent

    needsLayout

    Properties inherited from class javafx.scene.Node

    accessibleHelp, accessibleRoleDescription, accessibleRole, accessibleText, blendMode, boundsInLocal, boundsInParent, cacheHint, cache, clip, cursor, depthTest, disabled, disable, effectiveNodeOrientation, effect, eventDispatcher, focused, focusTraversable, focusVisible, focusWithin, 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
  • Field Summary

    Fields inherited from class javafx.scene.layout.Region

    USE_COMPUTED_SIZE, USE_PREF_SIZE

    Fields inherited from class javafx.scene.Node

    BASELINE_OFFSET_SAME_AS_HEIGHT
  • Constructor Summary

    Constructors
    Constructor
    Description
     
     
  • Method Summary

    Modifier and Type
    Method
    Description
    javafx.beans.property.BooleanProperty
     
    javafx.beans.property.ObjectProperty<javafx.scene.paint.Color>
     
    javafx.beans.property.ObjectProperty<javafx.scene.paint.Color>
     
    protected double
    computeMaxHeight(double WIDTH)
     
    protected double
    computeMaxWidth(double HEIGHT)
     
    protected double
    computeMinHeight(double WIDTH)
     
    protected double
    computeMinWidth(double HEIGHT)
     
    protected double
    computePrefHeight(double WIDTH)
     
    protected double
    computePrefWidth(double HEIGHT)
     
    javafx.beans.property.ObjectProperty<javafx.scene.paint.Color>
     
    javafx.beans.property.IntegerProperty
     
    void
     
    javafx.scene.paint.Color
    Returns the color that will be used to fill the background of the chart
    javafx.scene.paint.Color
    Returns the color that will be used by the autoTextColor feature as the bright text on dark segment fill colors
    javafx.collections.ObservableList<javafx.scene.Node>
     
    javafx.scene.paint.Color
    Returns the color that will be used by the autoTextColor feature as the dark text on bright segment fill colors
    int
    Returns the number of decimals that will be used to format the values in the tooltip
    javafx.scene.paint.Color
    Returns the color that will be used to draw text in segments if useChartItemTextColor == false
    Returns the orientation the text will be drawn in the segments
    boolean
    Returns true if the text color of the ChartItem elements should be used to fill the text in the segments
    boolean
    Returns true if the color of all chart segments in one group should be filled with the color of the groups root node or by the color defined in the chart data elements
    Returns the data that should be visualized in the chart segments
    javafx.beans.property.BooleanProperty
     
    boolean
    Returns true if the text color of the chart data should be adjusted according to the chart data fill color.
    boolean
    Returns true if the chart is drawn using Path elements, fire ChartItemEvents and show tooltips on segments.
    void
     
    void
    setAutoTextColor(boolean AUTOMATIC)
    Defines if the text color of the chart data should be adjusted according to the chart data fill color
    void
    setBackgroundColor(javafx.scene.paint.Color COLOR)
    Defines the color that will be used to fill the background of the chart
    void
    setBrightTextColor(javafx.scene.paint.Color COLOR)
    Defines the color that will be used by the autoTextColor feature as the bright text on dark segment fill colors
    void
    setDarkTextColor(javafx.scene.paint.Color COLOR)
    Defines the color that will be used by the autoTextColor feature as the dark text on bright segment fill colors
    void
    setDecimals(int DECIMALS)
    Defines the number of decimals that will be used to format the values in the tooltip
    void
    setInteractive(boolean INTERACTIVE)
    Defines if the chart should be drawn using Path elements, fire ChartItemEvents and shows tooltips on segments or if the the chart should be drawn using one Canvas node.
    void
    setTextColor(javafx.scene.paint.Color COLOR)
    Defines the color that will be used to draw text in segments if useChartItemTextColor == false
    void
    Defines the orientation the text will be drawn in the segments
    void
    Defines the root element of the tree
    void
    Defines if the text color of the segments should be taken from the ChartItem elements
    void
    setUseColorFromParent(boolean USE)
    Defines if tthe color of all chart segments in one group should be filled with the color of the groups root node or by the color defined in the chart data elements
    void
    Defines the data that should be visualized in the chart segments
    javafx.beans.property.ObjectProperty<javafx.scene.paint.Color>
     
    javafx.beans.property.ObjectProperty<TextOrientation>
     
    javafx.beans.property.BooleanProperty
     
    javafx.beans.property.BooleanProperty
     
    javafx.beans.property.ObjectProperty<VisibleData>
     

    Methods inherited from class javafx.scene.layout.Region

    backgroundProperty, borderProperty, cacheShapeProperty, centerShapeProperty, getBackground, getBorder, getClassCssMetaData, getCssMetaData, 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 inherited from class javafx.scene.Parent

    getBaselineOffset, getChildrenUnmodifiable, getManagedChildren, getStylesheets, isNeedsLayout, layout, lookup, needsLayoutProperty, queryAccessibleAttribute, requestLayout, requestParentLayout, setNeedsLayout, updateBounds

    Methods inherited from 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, focusVisibleProperty, focusWithinProperty, 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, getStyleClass, getTransforms, getTranslateX, getTranslateY, getTranslateZ, getTypeSelector, getUserData, getViewOrder, hasProperties, hoverProperty, idProperty, inputMethodRequestsProperty, intersects, intersects, isCache, isDisable, isDisabled, isFocused, isFocusTraversable, isFocusVisible, isFocusWithin, 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, 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, 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 inherited from class java.lang.Object

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

    Methods inherited from interface javafx.css.Styleable

    getStyleableNode
  • Property Details

  • Constructor Details

    • SunburstChart

      public SunburstChart()
    • SunburstChart

      public SunburstChart(TreeNode<T> TREE)
  • Method Details

    • layoutChildren

      public void layoutChildren()
      Overrides:
      layoutChildren in class javafx.scene.Parent
    • computeMinWidth

      protected double computeMinWidth(double HEIGHT)
      Overrides:
      computeMinWidth in class javafx.scene.layout.Region
    • computeMinHeight

      protected double computeMinHeight(double WIDTH)
      Overrides:
      computeMinHeight in class javafx.scene.layout.Region
    • computePrefWidth

      protected double computePrefWidth(double HEIGHT)
      Overrides:
      computePrefWidth in class javafx.scene.layout.Region
    • computePrefHeight

      protected double computePrefHeight(double WIDTH)
      Overrides:
      computePrefHeight in class javafx.scene.layout.Region
    • computeMaxWidth

      protected double computeMaxWidth(double HEIGHT)
      Overrides:
      computeMaxWidth in class javafx.scene.layout.Region
    • computeMaxHeight

      protected double computeMaxHeight(double WIDTH)
      Overrides:
      computeMaxHeight in class javafx.scene.layout.Region
    • getChildren

      public javafx.collections.ObservableList<javafx.scene.Node> getChildren()
      Overrides:
      getChildren in class javafx.scene.Parent
    • dispose

      public void dispose()
    • getVisibleData

      public VisibleData getVisibleData()
      Returns the data that should be visualized in the chart segments
      Returns:
      the data that should be visualized in the chart segments
    • setVisibleData

      public void setVisibleData(VisibleData VISIBLE_DATA)
      Defines the data that should be visualized in the chart segments
      Parameters:
      VISIBLE_DATA -
    • visibleDataProperty

      public javafx.beans.property.ObjectProperty<VisibleData> visibleDataProperty()
      See Also:
    • getTextOrientation

      public TextOrientation getTextOrientation()
      Returns the orientation the text will be drawn in the segments
      Returns:
      the orientation the text will be drawn in the segments
    • setTextOrientation

      public void setTextOrientation(TextOrientation ORIENTATION)
      Defines the orientation the text will be drawn in the segments
      Parameters:
      ORIENTATION -
    • textOrientationProperty

      public javafx.beans.property.ObjectProperty<TextOrientation> textOrientationProperty()
      See Also:
    • getBackgroundColor

      public javafx.scene.paint.Color getBackgroundColor()
      Returns the color that will be used to fill the background of the chart
      Returns:
      the color that will be used to fill the background of the chart
    • setBackgroundColor

      public void setBackgroundColor(javafx.scene.paint.Color COLOR)
      Defines the color that will be used to fill the background of the chart
      Parameters:
      COLOR -
    • backgroundColorProperty

      public javafx.beans.property.ObjectProperty<javafx.scene.paint.Color> backgroundColorProperty()
      See Also:
    • getTextColor

      public javafx.scene.paint.Color getTextColor()
      Returns the color that will be used to draw text in segments if useChartItemTextColor == false
      Returns:
      the color that will be used to draw text in segments if useChartItemTextColor == false
    • setTextColor

      public void setTextColor(javafx.scene.paint.Color COLOR)
      Defines the color that will be used to draw text in segments if useChartItemTextColor == false
      Parameters:
      COLOR -
    • textColorProperty

      public javafx.beans.property.ObjectProperty<javafx.scene.paint.Color> textColorProperty()
      See Also:
    • getUseColorFromParent

      public boolean getUseColorFromParent()
      Returns true if the color of all chart segments in one group should be filled with the color of the groups root node or by the color defined in the chart data elements
      Returns:
    • setUseColorFromParent

      public void setUseColorFromParent(boolean USE)
      Defines if tthe color of all chart segments in one group should be filled with the color of the groups root node or by the color defined in the chart data elements
      Parameters:
      USE -
    • useColorFromParentProperty

      public javafx.beans.property.BooleanProperty useColorFromParentProperty()
      See Also:
    • getDecimals

      public int getDecimals()
      Returns the number of decimals that will be used to format the values in the tooltip
      Returns:
    • setDecimals

      public void setDecimals(int DECIMALS)
      Defines the number of decimals that will be used to format the values in the tooltip
      Parameters:
      DECIMALS -
    • decimalsProperty

      public javafx.beans.property.IntegerProperty decimalsProperty()
      See Also:
    • isInteractive

      public boolean isInteractive()
      Returns true if the chart is drawn using Path elements, fire ChartItemEvents and show tooltips on segments.
      Returns:
    • setInteractive

      public void setInteractive(boolean INTERACTIVE)
      Defines if the chart should be drawn using Path elements, fire ChartItemEvents and shows tooltips on segments or if the the chart should be drawn using one Canvas node.
      Parameters:
      INTERACTIVE -
    • interactiveProperty

      public javafx.beans.property.BooleanProperty interactiveProperty()
      See Also:
    • isAutoTextColor

      public boolean isAutoTextColor()
      Returns true if the text color of the chart data should be adjusted according to the chart data fill color. e.g. if the fill color is dark the text will be set to the defined brightTextColor and vice versa.
      Returns:
      true if the text color of the chart data should be adjusted according to the chart data fill color
    • setAutoTextColor

      public void setAutoTextColor(boolean AUTOMATIC)
      Defines if the text color of the chart data should be adjusted according to the chart data fill color
      Parameters:
      AUTOMATIC -
    • autoTextColorProperty

      public javafx.beans.property.BooleanProperty autoTextColorProperty()
      See Also:
    • getBrightTextColor

      public javafx.scene.paint.Color getBrightTextColor()
      Returns the color that will be used by the autoTextColor feature as the bright text on dark segment fill colors
      Returns:
      the color that will be used by the autoTextColor feature as the bright text on dark segment fill colors
    • setBrightTextColor

      public void setBrightTextColor(javafx.scene.paint.Color COLOR)
      Defines the color that will be used by the autoTextColor feature as the bright text on dark segment fill colors
      Parameters:
      COLOR -
    • brightTextColorProperty

      public javafx.beans.property.ObjectProperty<javafx.scene.paint.Color> brightTextColorProperty()
      See Also:
    • getDarkTextColor

      public javafx.scene.paint.Color getDarkTextColor()
      Returns the color that will be used by the autoTextColor feature as the dark text on bright segment fill colors
      Returns:
      the color that will be used by the autoTextColor feature as the dark text on bright segment fill colors
    • setDarkTextColor

      public void setDarkTextColor(javafx.scene.paint.Color COLOR)
      Defines the color that will be used by the autoTextColor feature as the dark text on bright segment fill colors
      Parameters:
      COLOR -
    • darkTextColorProperty

      public javafx.beans.property.ObjectProperty<javafx.scene.paint.Color> darkTextColorProperty()
      See Also:
    • getUseChartItemTextColor

      public boolean getUseChartItemTextColor()
      Returns true if the text color of the ChartItem elements should be used to fill the text in the segments
      Returns:
      true if the text color of the segments will be taken from the ChartItem elements
    • setUseChartItemTextColor

      public void setUseChartItemTextColor(boolean USE)
      Defines if the text color of the segments should be taken from the ChartItem elements
      Parameters:
      USE -
    • useChartItemTextColor

      public javafx.beans.property.BooleanProperty useChartItemTextColor()
    • setTree

      public void setTree(TreeNode<T> TREE)
      Defines the root element of the tree
      Parameters:
      TREE -