Method SetAttributeValue
- Namespace
- PaintDotNet.Direct2D1
- Assembly
- PaintDotNet.Windows.dll
SetAttributeValue(string, SvgAttributeStringType, string)
Sets an attribute of this element using a string.
void SetAttributeValue(string name, SvgAttributeStringType type, string value)
Parameters
name
stringName of the attribute to set.
type
SvgAttributeStringTypeThe type of the string.
value
stringThe new value of the attribute.
Remarks
Throws an exception if the attribute name is not valid on this element.
Throws an exception if the attribute cannot be expressed as the specified type.
SetAttributeValue(string, SvgAttributePodType, ReadOnlySpan<byte>)
Sets an attribute of this element using a POD (plain old date) type.
void SetAttributeValue(string name, SvgAttributePodType type, ReadOnlySpan<byte> value)
Parameters
name
stringName of the attribute to set.
type
SvgAttributePodTypeThe POD type of the attribute.
value
ReadOnlySpan<byte>A buffer with the new value of the attribute.
Remarks
Throws an exception if the attribute name is not valid on this element.
Throws an exception if the attribute cannot be expressed as the specified type.
SetAttributeValue(string, ISvgAttribute)
Sets an attribute of this element using an object reference. A given attribute object may only set on one element in one attribute location at a time.
void SetAttributeValue(string name, ISvgAttribute value)
Parameters
name
stringName of the attribute to set.
value
ISvgAttributeThe new value of the attribute.
Remarks
Throws an exception if the attribute name is not valid on this element.
Throws an exception if the attribute cannot be expressed as the specified interface type.
Throws an exception if the attribute object is already set on an element.