Interface ILspLabelingAlgorithm

All Superinterfaces:
Cloneable, ILcdCloneable
All Known Implementing Classes:
ALspDiscreteLabelingAlgorithm, ALspDiscreteLabelingAlgorithmWrapper, TLspCompositeDiscreteLabelingAlgorithm, TLspCompositeLabelingAlgorithm, TLspContinuousLabelingAlgorithm, TLspCurvedPathLabelingAlgorithm, TLspDependentLabelsRemovalWrapper, TLspInPathLabelingAlgorithm, TLspLabelingAlgorithm, TLspOnPathLabelingAlgorithm

public interface ILspLabelingAlgorithm extends ILcdCloneable

This interface can be used to compute placements for labels. It consists of a method to compute label placements. This method gets a List of TLspLabelIDs as input, and outputs a List of TLspLabelPlacements, each pointing to its label.

The returned List of TLcdLabelPlacements contains label placements that are either visible or invisible. When a placement is present in the list, it means that the location should be stored. When a placement in the list is marked as visible, it means that its location should be marked as visible in the label placer.

Since:
2012.0
  • Method Details

    • placeLabels

      List<TLspLabelPlacement> placeLabels(List<TLspLabelID> aLabelIDs, ILspLabelingAlgorithm.LabelContext aLabelContext, ILspLabelConflictChecker aConflictChecker, ILspView aView)

      This method computes a list of label placements for the given List of labels. The returned label placements should contain a valid label location and label bounds. They should also point to their corresponding TLspLabelID

      The returned List of TLspLabelPlacements contains label placements that are either visible or invisible. When a placement is present in the list, it means that the location should be stored. When a placement in the list is marked as visible, it means that its location should be marked as visible in the label placer

      Parameters:
      aLabelIDs - the labels to be placed.
      aLabelContext - provides context information, such as priorities, PaintState, ...
      aConflictChecker - the conflict checker that can be used to detect conflicts between labels.
      aView - the view.
      Returns:
      a list of label placements.