Class NativeNode
It provides support to embed SVG element into a node. To create a native node, the type node should be set as “nativeâ€.
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Syncfusion.JavaScript.DataVisualization.Models.Diagram
Assembly: Syncfusion.EJ.dll
Syntax
public class NativeNode : Node
Constructors
NativeNode()
Initializes a new instance of the NativeNode class.
Declaration
public NativeNode()
NativeNode(NativeNode)
Initializes a new instance of the NativeNode class.
Declaration
public NativeNode(NativeNode src)
Parameters
| Type | Name | Description |
|---|---|---|
| NativeNode | src |
Properties
ContentAlignment
Declaration
[JsonConverter(typeof(StringEnumConverter))]
[JsonProperty("contentAlignment")]
public ContentAlignment ContentAlignment { get; set; }
Property Value
| Type | Description |
|---|---|
| ContentAlignment |
Scale
Declaration
[JsonConverter(typeof(StringEnumConverter))]
[JsonProperty("scale")]
public ScaleConstraints Scale { get; set; }
Property Value
| Type | Description |
|---|---|
| ScaleConstraints |
TemplateId
Gets or sets the id of svg/html templates. Applicable, if the node is html or native.
Declaration
[JsonProperty("templateId")]
public string TemplateId { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String | String.Empty |
Examples
  <script id="svgTemplate" type="text/x-jsrender">
      <svg version="1.0" xmlns="http://www.w3.org/2000/svg" width="70px" height="30px">
          <g visibility="visible">
              <image width="70px" height="35px" opacity="1" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="{{:addInfo.source}}"></image>
              <text x="25" y="20" font-size="11" style="height:30px">
                  <tspan>{{:name}}</tspan>
              </text>
          </g>
      </svg>
  </script>
      NativeNode Node = new NativeNode()
      {
          Name = "bpmn",
          TemplateId = "svgTemplate"
      };
Methods
Clone()
Performs a deep copy of the set of matched elements, meaning that it copies the matched elements as well as all of their descendant elements.
Declaration
public override object Clone()
Returns
| Type | Description |
|---|---|
| System.Object | object |