HighlightingStyleColorPaletteSerializer Class
Provides a class that can serialize and deserialize the registered colors of a IHighlightingStyleColorPalette to and from XML.
public class HighlightingStyleColorPaletteSerializer
- Inheritance:
- object object
Constructors
HighlightingStyleColorPaletteSerializer()
Initializes an instance of the class.
public HighlightingStyleColorPaletteSerializer()
Methods
Deserialize(IHighlightingStyleColorPalette, string)
Clears all colors in the given color palette then loads the colors from the previously serialized data.
public static void Deserialize(IHighlightingStyleColorPalette colorPalette, string xml)
Parameter | Type | Description |
---|---|---|
colorPalette | IHighlightingStyleColorPalette | The color palette to populate. |
xml | string | The previously serialized data. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException |
See Also
Serialize(IHighlightingStyleColorPalette)
Serializes all configured colors in the given color palette.
public static string Serialize(IHighlightingStyleColorPalette colorPalette)
Parameter | Type | Description |
---|---|---|
colorPalette | IHighlightingStyleColorPalette | The color palette to read. |
Returns
- string:
The serialized data, which can be used to Deserialize(IHighlightingStyleColorPalette, string) the color palette.
Exceptions
Type | Condition |
---|---|
ArgumentNullException |