Blazor

Upgrade Guide User Guide Demos Support Forums Download
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class PathElement - Blazor API Reference | Syncfusion

    Show / Hide Table of Contents

    Class PathElement

    Represents the class which defines how to align the path based on offsetX and offsetY.

    Inheritance
    System.Object
    CommonElement
    DiagramElement
    PathElement
    Inherited Members
    CommonElement.ID
    CommonElement.Pivot
    CommonElement.IsDirt
    CommonElement.Visible
    CommonElement.OffsetX
    CommonElement.OffsetY
    CommonElement.CornerRadius
    CommonElement.MinHeight
    CommonElement.MinWidth
    CommonElement.MaxWidth
    CommonElement.MaxHeight
    CommonElement.Width
    CommonElement.Height
    CommonElement.RotationAngle
    CommonElement.Margin
    CommonElement.HorizontalAlignment
    CommonElement.VerticalAlignment
    CommonElement.RelativeMode
    CommonElement.Style
    CommonElement.ParentID
    CommonElement.DesiredSize
    CommonElement.ActualSize
    CommonElement.Bounds
    CommonElement.Shadow
    CommonElement.OuterBounds
    Namespace: Syncfusion.Blazor.Diagram
    Assembly: Syncfusion.Blazor.dll
    Syntax
    public class PathElement : DiagramElement
    Examples
    <SfDiagramComponent Width="1000px" Height="1000px" @bind-Nodes="Nodes" SetNodeTemplate="SetTemplate">
    </SfDiagramComponent>    
    @code
    { 
      DiagramObjectCollection<Node> Nodes = new DiagramObjectCollection<Node>();
      private ICommonElement SetTemplate(IDiagramObject node)
      {
        if ((node as Node).ID == "node2")
        {
          DiagramCanvas container = new DiagramCanvas();
          PathElement diagramElement = new PathElement();
          diagramElement.Style.Fill = "green";
          diagramElement.Data = "M150 0 L75 200 L225 200 Z";
          container.Children.Add(diagramElement);
          return container;
        }
        return null;
      }
    }

    Constructors

    PathElement()

    Initializes a new instance of the PathElement class.

    Declaration
    public PathElement()

    PathElement(PathElement)

    Creates a new instance of the PathElement from the given PathElement.

    Declaration
    public PathElement(PathElement src)
    Parameters
    Type Name Description
    PathElement src

    path element.

    Properties

    AbsolutePath

    Gets or sets the equivalent path, that will have the origin as 0,0.

    Declaration
    public string AbsolutePath { get; set; }
    Property Value
    Type Description
    System.String

    Data

    Gets or sets the geometry of the path element.

    Declaration
    public string Data { get; set; }
    Property Value
    Type Description
    System.String

    TransformPath

    Gets or sets whether the path has to be transformed to fit the given x,y, width, height.

    Declaration
    public bool TransformPath { get; set; }
    Property Value
    Type Description
    System.Boolean

    Methods

    Clone()

    Creates a new element that is a copy of the current path element

    Declaration
    public override object Clone()
    Returns
    Type Description
    System.Object
    Overrides
    DiagramElement.Clone()
    Back to top Generated by DocFX
    Copyright © 2001 - 2022 Syncfusion Inc. All Rights Reserved