Enum SnapConstraints
Enables or disables certain features of snapping.
Namespace: Syncfusion.Blazor.Diagram
Assembly: Syncfusion.Blazor.dll
Syntax
[Flags]
public enum SnapConstraints
Examples
<SfDiagramComponent @bind-Constraints="@diagramConstraints" Height="600px" />
<SnapSettings @ref="snapSettings" @bind-Constraints="@Constraints" />
@code
{
SnapSettings snapSettings;
SnapConstraints Constraints = SnapConstraints.All;
DiagramObjectCollection<Node> nodes = new DiagramObjectCollection<Node>();
protected override void OnInitialized()
{
}
}
Fields
| Name | Description |
|---|---|
| All | Enables all the functionalities of snapping. |
| None | Disables all the functionalities of snapping. |
| ShowHorizontalLines | Displays only the horizontal grid lines in the diagram. |
| ShowLines | Display both the horizontal and the vertical grid lines. |
| ShowVerticalLines | Displays only the vertical grid lines in the diagram. |
| SnapToHorizontalLines | Enables the object to snap only with horizontal grid lines. |
| SnapToLines | Enables the object to snap with both the horizontal and vertical grid lines. |
| SnapToObject | Enables the object to snap with other objects in the diagram. |
| SnapToVerticalLines | Enables the object to snap only with vertical grid lines. |