menu

Blazor

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class SubTreeAlignmentType - Blazor API Reference | Syncfusion

    Show / Hide Table of Contents

    Class SubTreeAlignmentType

    Specifies the collection of sub tree alignments in an organizational chart.

    Inheritance
    System.Object
    SubTreeAlignmentType
    Namespace: Syncfusion.Blazor.Diagram
    Assembly: Syncfusion.Blazor.dll
    Syntax
    public sealed class SubTreeAlignmentType : Enum
    Examples
    <SfDiagramComponent Height = "600px" NodeCreating="@NodeDefaults" ConnectorCreating="@ConnectorDefaults">
        <DataSourceSettings ID = "Id" ParentID="Team" DataSource="@DataSource"></DataSourceSettings>   
        <Layout Type = "LayoutType.OrganizationalChart"
                @bind-HorizontalSpacing="@HorizontalSpacing" 
                @bind-VerticalSpacing="@VerticalSpacing" 
                GetLayoutInfo="GetLayoutInfo">
        </Layout>
    </SfDiagramComponent>
    @code
    {
       public class OrgChartDataModel 
       {
           public string Id  { get; set; }
           public string Team { get; set; }
           public string Role { get; set; }
       }
       public object DataSource = new List<object>()
       {
           new OrgChartDataModel() { Id= "1", Role= "General Manager" },
           new OrgChartDataModel() { Id= "2", Role= "Human Resource Manager", Team= "1" },
           new OrgChartDataModel() { Id= "3", Role= "Design Manager", Team= "1" },
           new OrgChartDataModel() { Id= "4", Role= "Operation Manager", Team= "1" },
           new OrgChartDataModel() { Id= "5", Role= "Marketing Manager", Team= "1" }
       };
    }

    Fields

    Alternate

    Aligns the child nodes alternatively on both left and right sides in a vertical sub tree.

    Declaration
    public const SubTreeAlignmentType Alternate
    Field Value
    Type
    SubTreeAlignmentType

    Balanced

    Aligns the child nodes horizontally to balance the width and height of the sub tree.

    Declaration
    public const SubTreeAlignmentType Balanced
    Field Value
    Type
    SubTreeAlignmentType

    Center

    Aligns the child nodes at the center of the parent in a horizontal sub tree.

    Declaration
    public const SubTreeAlignmentType Center
    Field Value
    Type
    SubTreeAlignmentType

    Left

    Aligns the child nodes at the left of the parent in a horizontal/vertical sub tree.

    Declaration
    public const SubTreeAlignmentType Left
    Field Value
    Type
    SubTreeAlignmentType

    Right

    Aligns the child nodes at the right of the parent in a horizontal/vertical sub tree.

    Declaration
    public const SubTreeAlignmentType Right
    Field Value
    Type
    SubTreeAlignmentType
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved