MarkupAttribute

Struct in Yarn.Markup

Inherits from System.ValueType

Summary

Represents a range of text in a marked-up string.

public struct MarkupAttribute

Remarks

You do not create instances of this struct yourself. It is created by objects that can parse markup, such as LineParser .

Methods

NameDescription
Shift(int)Creates a new MarkupAttribute based on the current instance whose Position is shifted towards the end of the string by shift characters.
ToString()
TryGetProperty(string,bool)Gets a boolean property named name from this attribute, if present.
TryGetProperty(string,int)Gets an integer property named name from this attribute, if present.
TryGetProperty(string,float)Gets a float property named name from this attribute, if present.
TryGetProperty(string,string?)Gets a string property named name from this attribute, if present.
TryGetProperty(string,MarkupValue)Gets a property named name from this attribute, if present.

Properties

NameDescription
LengthGets the number of text elements in the plain text that this attribute covers.
NameGets the name of the attribute.
PositionGets the position in the plain text where this attribute begins.
PropertiesGets the properties associated with this attribute.

See Also

  • Yarn.Markup.LineParser.ParseString(System.String,System.String,System.Boolean,System.Boolean,System.Boolean):