alexa
menu

Blazor

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Search Results for

    Show / Hide Table of Contents

    Class UmlSectionHeaderSettings

    Represents the configuration settings for a UML section header, such as Attributes, Methods, or Members.

    Inheritance
    object
    DiagramObject
    UmlSectionHeaderSettings
    Implements
    IDiagramObject
    ICloneable
    Inherited Members
    DiagramObject.GetParent()
    DiagramObject.OnPropertyChanged(string, object, object, IDiagramObject)
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Syncfusion.Blazor.Diagram
    Assembly: Syncfusion.Blazor.Diagram.dll
    Syntax
    public class UmlSectionHeaderSettings : DiagramObject, IDiagramObject, ICloneable
    Remarks

    This includes header text, styling, action visibility, and expand/collapse behavior.

    Examples
    nodes.Add(new Node()
    {
        ID = "classNode",
        OffsetX = 250,
        OffsetY = 250,
        Width = 200,
        Height = 200,
        Shape = new UmlClassifierShape()
        {
            Classifier = ClassifierShape.Class,
            ClassShape = new UmlClass()
            {
                Name = "Customer",
                AttributeHeaderSettings = new UmlSectionHeaderSettings()
                {
                    HeaderText = "Properties",
                    ShowExpandCollapseIcon = true,
                    IsExpanded = true
                },
                MethodHeaderSettings = new UmlSectionHeaderSettings()
                {
                    HeaderText = "Operations",
                    EnableAddAction = false
                }
            }
        }
    });

    Constructors

    UmlSectionHeaderSettings()

    Initializes a new instance of the UmlSectionHeaderSettings.

    Declaration
    public UmlSectionHeaderSettings()

    UmlSectionHeaderSettings(UmlSectionHeaderSettings)

    Initializes a new instance of the UmlSectionHeaderSettings class by copying an existing instance.

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

    The source UmlSectionHeaderSettings to copy.

    Properties

    EnableAddAction

    Gets or sets a value indicating whether the add action ("+") button is visible and enabled in the section header.

    Declaration
    public bool EnableAddAction { get; set; }
    Property Value
    Type Description
    bool

    A bool indicating whether the add option is visible. The default value is true.

    Remarks

    When enabled, an add ("+") action is shown in the header, allowing users to dynamically add items to the section.

    Examples

    This example disables the add action:

    AttributeHeaderSettings = new UmlSectionHeaderSettings()
    {
        EnableAddAction = false
    }

    EnableRemoveAction

    Gets or sets a value indicating whether the remove action ("–") button is visible and enabled in the section header.

    Declaration
    public bool EnableRemoveAction { get; set; }
    Property Value
    Type Description
    bool

    A bool indicating whether the remove option is visible. The default value is true.

    Remarks

    When enabled, a remove ("-") action is displayed in the header, allowing users to remove items from the section.

    Examples

    This example disables the remove action:

    AttributeHeaderSettings = new UmlSectionHeaderSettings()
    {
        EnableRemoveAction = false
    }

    HeaderText

    Gets or sets the text displayed in the section header (e.g., "Attributes", "Operations", "Members").

    Declaration
    public string HeaderText { get; set; }
    Property Value
    Type Description
    string

    A string representing the header title.

    Remarks

    This property defines the visible title for the section, such as "Attributes", "Operations", or "Members".

    Examples

    This example demonstrates setting custom header text:

    AttributeHeaderSettings = new UmlSectionHeaderSettings()
    {
        HeaderText = "Properties"
    }

    IsExpanded

    Gets or sets whether the section content is currently expanded or collapsed.

    Declaration
    public bool IsExpanded { get; set; }
    Property Value
    Type Description
    bool

    A bool indicating whether the section content is visible. The default value is true.

    Remarks

    When set to true, the section displays its contents. When false, the section remains collapsed.

    Examples

    This example demonstrates collapsing a section:

    MethodHeaderSettings = new UmlSectionHeaderSettings()
    {
        IsExpanded = false
    }

    ShowExpandCollapseIcon

    Gets or sets a value indicating whether the expand or collapse toggle icon is visible.

    Declaration
    public bool ShowExpandCollapseIcon { get; set; }
    Property Value
    Type Description
    bool

    A bool indicating whether the toggle icon is displayed. The default value is true.

    Remarks

    When enabled, users can toggle the visibility of the section content using an expand/collapse icon in the header.

    Examples

    This example hides the expand/collapse icon:

    AttributeHeaderSettings = new UmlSectionHeaderSettings()
    {
        ShowExpandCollapseIcon = false
    }

    Style

    Gets or sets the text style applied to the header.

    Declaration
    public TextStyle? Style { get; set; }
    Property Value
    Type Description
    TextStyle

    A TextStyle defining the appearance of the header text and background.

    Remarks

    This property allows customization of font, color, fill, and other styling aspects of the section header.

    Examples

    This example demonstrates applying style to a header:

    AttributeHeaderSettings = new UmlSectionHeaderSettings()
    {
        Style = new TextStyle()
        {
            Fill = "yellow",
            Color = "black"
        }
    }

    Methods

    Clone()

    Creates a new object that is a copy of the current UmlSectionHeaderSettings.

    Declaration
    public object Clone()
    Returns
    Type Description
    object

    A new UmlSectionHeaderSettings instance that is a deep copy of the current object.

    Implements

    IDiagramObject
    ICloneable
    In this article
    Back to top Generated by DocFX
    Copyright © 2001 - 2026 Syncfusion Inc. All Rights Reserved