Blazor

Code Examples Upgrade Guide User Guide Demos Support Forums Download
  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class Palette

    Show / Hide Table of Contents

    Class Palette

    A palette displays a set of similar symbols and annotates the group textually with its heading.

    Inheritance
    System.Object
    Palette
    Implements
    IPaletteObject
    IDiagramObject
    System.ICloneable
    Namespace: Syncfusion.Blazor.Diagram.SymbolPalette
    Assembly: Syncfusion.Blazor.dll
    Syntax
    public class Palette : Object, IPaletteObject, IDiagramObject, ICloneable
    Examples
    new Palette()
    {
        Id = "BasicShape",
        Expanded = true,
        Symbols = BasicShape,
        Title = "Basic Shapes",
        IconCss = "e-ddb-icons e-basic"
    }

    Constructors

    Palette()

    Declaration
    public Palette()

    Properties

    IconCss

    Represents the class of the symbol group. By default, it is empty.

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

    the default value is empty

    Examples
    <SfSymbolPaletteComponent Height="600px" Palettes="@Palettes">
    </SfSymbolPaletteComponent >
    @code
    { 
    DiagramObjectCollection<Palette> Palettes;
     Palettes = new DiagramObjectCollection<Palette>(){
     new Palette(){Symbols =Tnodes,Title="Flow Shapes",ID="Flow Shapes",IsExpanded = false },
     };
    }

    ID

    Represents the unique id of a symbol group. By default, it is empty.

    Declaration
    public string ID { get; set; }
    Property Value
    Type Description
    System.String
    Examples
    <SfSymbolPaletteComponent Height="600px" Palettes="@Palettes">
    </SfSymbolPaletteComponent >
    @code
    { 
    DiagramObjectCollection<Palette> Palettes;
     Palettes = new DiagramObjectCollection<Palette>(){
     new Palette(){Symbols =Tnodes,Title="Flow Shapes",ID="Flow Shapes" },
     };
    }

    IsExpanded

    Gets or sets whether the palette items are to be expanded or not. By default, it is true.

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

    true, palette items are to be expanded; Otherwise false.

    Examples
    <SfSymbolPaletteComponent Height="600px" Palettes="@Palettes">
    </SfSymbolPaletteComponent >
    @code
    { 
    DiagramObjectCollection<Palette> Palettes;
     Palettes = new DiagramObjectCollection<Palette>(){
     new Palette(){Symbols =Tnodes,Title="Flow Shapes",ID="Flow Shapes",IsExpanded = false },
     };
    }

    Symbols

    Represents the collection of predefined symbols.

    Declaration
    public DiagramObjectCollection<NodeBase> Symbols { get; set; }
    Property Value
    Type Description
    DiagramObjectCollection<NodeBase>
    Examples
    <SfSymbolPaletteComponent Height="600px" Palettes="@Palettes">
    </SfSymbolPaletteComponent >
    @code
    { 
    DiagramObjectCollection<Palette> Palettes;
     Palettes = new DiagramObjectCollection<Palette>(){
     new Palette(){Symbols =Tnodes,Title="Flow Shapes",ID="Flow Shapes",IsExpanded = false },
     };
    }

    Title

    Represents the title of the symbol group. By default, it is empty.

    Declaration
    public string Title { get; set; }
    Property Value
    Type Description
    System.String
    Examples
    <SfSymbolPaletteComponent Height="600px" Palettes="@Palettes">
    </SfSymbolPaletteComponent >
    @code
    { 
    DiagramObjectCollection<Palette> Palettes;
     Palettes = new DiagramObjectCollection<Palette>(){
     new Palette(){Symbols =Tnodes,Title="Flow Shapes",ID="Flow Shapes",IsExpanded = false },
     };
    }

    Methods

    Clone()

    Creates a new palette that is a copy of the current palette.

    Declaration
    public object Clone()
    Returns
    Type Description
    System.Object

    Palette

    OnPropertyChanged(String, Object, Object, IDiagramObject)

    Invoked when the effective value of any property on this Symbol palette object has been updated.

    Declaration
    public void OnPropertyChanged(string propertyName, object newVal, object oldVal, IDiagramObject container)
    Parameters
    Type Name Description
    System.String propertyName

    string that contains the propertyname.

    System.Object newVal

    An object that contain newvalue, which means new value of property

    System.Object oldVal

    An object that contain oldvalue, which means old value of property

    IDiagramObject container

    An IDiagramObject that contain IDiagram object

    OnPropertyChanged(String, Object, Object, IPaletteObject)

    Invoked when the effective value of any property on this Symbol palette object has been updated.

    Declaration
    public void OnPropertyChanged(string propertyName, object newVal, object oldVal, IPaletteObject container)
    Parameters
    Type Name Description
    System.String propertyName

    string that contains the propertyname.

    System.Object newVal

    An object that contain newvalue, which means new value of property

    System.Object oldVal

    An object that contain oldvalue, which means old value of property

    IPaletteObject container

    An IPaletteObject that contain palette object

    Implements

    IPaletteObject
    IDiagramObject
    System.ICloneable
    Back to top Generated by DocFX
    Copyright © 2001 - 2023 Syncfusion Inc. All Rights Reserved