MathDomNode
Namespace: Temml
public abstract class MathDomNodeThe base of the nodes of a build tree. Maps to the node classes of src/tree.js, src/domTree.js and src/mathMLTree.js.
Inheritance: object
Derived: AnchorNode, DocumentFragment, HtmlTextNode, Img, MathNode, Span, TextNode
Properties
Section titled “Properties”Attributes
Section titled “Attributes”public DomPropertyMap Attributes { get; set; }The attributes.
Value: DomPropertyMap
Children
Section titled “Children”public List<MathDomNode> Children { get; set; }The child nodes.
Value: List<MathDomNode>
Classes
Section titled “Classes”public List<string> Classes { get; set; }The CSS classes.
Value: List<string>
public DomPropertyMap Style { get; set; }The inline style, with camel case names.
Value: DomPropertyMap
public string? Type { get; set; }The tag name of a MathNode; null for other nodes.
Value: string
Methods
Section titled “Methods”GetAttribute(string)
Section titled “GetAttribute(string)”public string? GetAttribute(string name)Gets an attribute, or null.
Parameters
| Name | Type | Description |
|---|---|---|
name |
string |
Returns: string
HasClass(string)
Section titled “HasClass(string)”public bool HasClass(string className)Whether the node has the CSS class.
Parameters
| Name | Type | Description |
|---|---|---|
className |
string |
Returns: bool
SetAttribute(string, string?)
Section titled “SetAttribute(string, string?)”public virtual void SetAttribute(string name, string? value)Sets an attribute.
Parameters
| Name | Type | Description |
|---|---|---|
name |
string | |
value |
string |
ToMarkup()
Section titled “ToMarkup()”public string ToMarkup()Converts the node and its children into markup.
Returns: string
ToText()
Section titled “ToText()”public virtual string ToText()The text of the node and its children, similar to innerText.
Returns: string
MIT · Copyright 2020 Ron Kok · unofficial community port of Temml