Class EdgeLabelPart

All Implemented Interfaces:
IActivatable, IAdaptable, IAdaptable.Bound<IViewer>, IDisposable, IContentPart<javafx.scene.Group>, ITransformableContentPart<javafx.scene.Group>, IVisualPart<javafx.scene.Group>

public class EdgeLabelPart extends AbstractLabelPart
The EdgeLabelPart is an AbstractLabelPart that is used to display the label of an edge.
  • Constructor Details

    • EdgeLabelPart

      public EdgeLabelPart()
  • Method Details

    • computeLabelPosition

      public Point computeLabelPosition()
      Description copied from class: AbstractLabelPart
      Computes a position for this label.
      Specified by:
      computeLabelPosition in class AbstractLabelPart
      Returns:
      The computed position for this label in the coordinate system of the GraphPart that contains this label.
    • doCreateVisual

      protected javafx.scene.Group doCreateVisual()
      Specified by:
      doCreateVisual in class AbstractVisualPart<javafx.scene.Group>
    • doGetContentAnchorages

      protected SetMultimap<? extends Object,String> doGetContentAnchorages()
      Specified by:
      doGetContentAnchorages in class AbstractContentPart<javafx.scene.Group>
    • doRefreshVisual

      protected void doRefreshVisual(javafx.scene.Group visual)
      Specified by:
      doRefreshVisual in class AbstractVisualPart<javafx.scene.Group>
    • getContent

      public javafx.util.Pair<Edge,String> getContent()
      Specified by:
      getContent in interface IContentPart<javafx.scene.Group>
      Overrides:
      getContent in class AbstractLabelPart
    • getEndPoint

      protected Point getEndPoint()
      Computes the end position for placing a label. The position is interpreted in the parent coordinate system of this part's visual.
      Returns:
      The end position for placing a label.
    • getFirstAnchorage

      protected IContentPart<? extends Connection> getFirstAnchorage()
      Returns the IContentPart for which this EdgeLabelPart displays the label.
      Returns:
      The IContentPart for which this EdgeLabelPart displays the label.
    • getMidPoint

      protected Point getMidPoint()
      Computes the middle position for placing a label. The position is interpreted in the parent coordinate system of this part's visual.
      Returns:
      The middle position for placing a label.
    • getStartPoint

      protected Point getStartPoint()
      Computes the start position for placing a label. The position is interpreted in the parent coordinate system of this part's visual.
      Returns:
      The start position for placing a label.
    • getTooltipNodes

      protected javafx.scene.control.Tooltip[] getTooltipNodes()
      Array containing the Tooltip nodes of this EdgeLabelPart in the following order:
      • [0]: tooltip node on the label of the edge.
      • [1]: tooltip node on the source label of the edge.
      • [2]: tootlip node on the target label of the edge.
      • [3]: tooltip node on the external label of the edge.
      Returns:
      Array of Tooltips.
      Since:
      5.1
    • refreshTooltip

      protected void refreshTooltip()
      Changes the tooltip of this EdgeLabelPart to the given value.
      Since:
      5.1
    • refreshTooltip

      protected void refreshTooltip(javafx.scene.control.Tooltip tooltipNode, String tooltip)
      Changes the tooltip of this EdgeLabelPart to the given value.
      Parameters:
      tooltipNode - the tooltip node
      tooltip - the tooltip text
      Since:
      5.1