Class SFChartColorModel
SFChartColorModel contains a number of predefined color palette and have custom brushes collection to populate a custom palette.
Inheritance
System.Object
SFChartColorModel
Namespace: Syncfusion.MacOS.Charts.SfChart
Assembly: Syncfusion.SfChart.XForms.macOS.dll
Syntax
public class SFChartColorModel : Object
Constructors
SFChartColorModel(SFChartColorPalette)
Initializes a new instance of the SFChartColorModel class with single arguments
Declaration
public SFChartColorModel(SFChartColorPalette palette)
Parameters
Type | Name | Description |
---|---|---|
SFChartColorPalette | palette |
Properties
CustomColors
Gets or sets the list of colors to be used as custom palette.
Declaration
public NSArray CustomColors { get; set; }
Property Value
Type |
---|
Foundation.NSArray |
CustomGradientColors
Gets or sets the collection of custom gradient colors in custom palette.
Declaration
public ChartGradientColorCollection CustomGradientColors { get; set; }
Property Value
Type |
---|
ChartGradientColorCollection |
Palette
Gets or sets the color model with defined palette.
Declaration
public SFChartColorPalette Palette { get; set; }
Property Value
Type |
---|
SFChartColorPalette |
Methods
GetColor(Int32)
Returns the brush at the specified index for current palette
Declaration
public NSColor GetColor(int colorIndex)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | colorIndex | The color index. |
Returns
Type | Description |
---|---|
AppKit.NSColor | The color |
GetColors(SFChartColorPalette)
Returns the collection of brushes for specified palette
Declaration
public List<NSColor> GetColors(SFChartColorPalette palette)
Parameters
Type | Name | Description |
---|---|---|
SFChartColorPalette | palette | The ChartColorPalette |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<AppKit.NSColor> | List of brushes |