Specifies discrete positions for placing edge labels with the GenericLabeling algorithm.
Remarks
This enumeration defines various label positions along an edge in a graph, allowing for precise control over the placement of labels relative to the edge's path. The positions can be combined using a bitwise OR operation to specify multiple valid locations for label placement.
See Also
Members
No filters for this type
Constants
To define multiple valid placements for a label, all position specifiers can be combined with a logical
or-operation.static
Sample Graphs
ShownSetting: Label at the center position
Position mask that constrains the allowed positions to the CENTER of the edge's path.
Position mask that constrains the allowed positions to the CENTER of the edge's path.
To define multiple valid placements for a label, all position specifiers can be combined with a logical
or-operation.static
Sample Graphs
ShownSetting: Label at the head position
Two of the positions are near the source and two others are near the target. The remaining positions are in the middle of the edge.
static
Sample Graphs
ShownSetting: The six positions beside the edge are valid
See Also
API
- SOURCE_HEAD, SOURCE_TAIL, HEAD, TAIL, TARGET_HEAD, TARGET_TAIL
To define multiple valid placements for a label, all position specifiers can be combined with a logical
or-operation.static
Sample Graphs
ShownSetting: Label at the source center position
To define multiple valid placements for a label, all position specifiers can be combined with a logical
or-operation.static
Sample Graphs
ShownSetting: Label at the source head position
To define multiple valid placements for a label, all position specifiers can be combined with a logical
or-operation.static
Sample Graphs
ShownSetting: Label at the source tail position
To define multiple valid placements for a label, all position specifiers can be combined with a logical
or-operation.static
Sample Graphs
ShownSetting: Label at the tail position
To define multiple valid placements for a label, all position specifiers can be combined with a logical
or-operation.static
Sample Graphs
ShownSetting: Label at tail center position
To define multiple valid placements for a label, all position specifiers can be combined with a logical
or-operation.static
Sample Graphs
ShownSetting: Label at the target head position
To define multiple valid placements for a label, all position specifiers can be combined with a logical
or-operation.static
Sample Graphs
ShownSetting: Label at the target tail position
static
Sample Graphs
ShownSetting: The three positions on the edge are valid
See Also
Static Methods
Converts the given argument to an enum constant of this enum type.
Converts the given argument to an enum constant of this enum type.
Most notably, this method can convert an enum constant's name into the enum constant itself.
static
Parameters
- value: DiscreteEdgeLabelPositions
- The value to convert to an enum constant.
Return Value
- DiscreteEdgeLabelPositions
- The enum constant that corresponds to the given argument.
Returns the name of the given enum constant.
Returns the name of the given enum constant.
static
Parameters
- value: DiscreteEdgeLabelPositions
- The numeric value of an enum constant.
Return Value
- string
- The name of the enum constant.
Throws
- Exception ({ name: 'Error' })
- If this type is a flags enums, and the provided value doesn't correspond to a single enum constant, or if this enum type contains no constant of the given numeric value.