In This Article

ColorPalette Class

Stores information about a palette that consists of multiple color ramps.

public class ColorPalette
Inheritance:
object object

Constructors

ColorPalette(ThemeDefinition)

Initializes an instance of the ColorPalette class.

public ColorPalette(ThemeDefinition definition)
Parameter Type Description
definition ThemeDefinition

The ThemeDefinition to examine.

Properties

All

Gets the collection of all color ramps in the palette.

public IEnumerable<IColorRamp> All { get; }

Property Value

IEnumerable<IColorRamp>:

The collection of all color ramps in the palette.

Blue

Gets the blue color ramp.

public IColorRamp Blue { get; }

Property Value

IColorRamp:

The blue color ramp.

Gray

Gets the gray color ramp.

public IColorRamp Gray { get; }

Property Value

IColorRamp:

The gray color ramp.

Green

Gets the green color ramp.

public IColorRamp Green { get; }

Property Value

IColorRamp:

The green color ramp.

Indigo

Gets the indigo color ramp.

public IColorRamp Indigo { get; }

Property Value

IColorRamp:

The indigo color ramp.

Orange

Gets the orange color ramp.

public IColorRamp Orange { get; }

Property Value

IColorRamp:

The orange color ramp.

Pink

Gets the pink color ramp.

public IColorRamp Pink { get; }

Property Value

IColorRamp:

The pink color ramp.

Purple

Gets the purple color ramp.

public IColorRamp Purple { get; }

Property Value

IColorRamp:

The purple color ramp.

Red

Gets the red color ramp.

public IColorRamp Red { get; }

Property Value

IColorRamp:

The red color ramp.

Silver

Gets the silver color ramp.

public IColorRamp Silver { get; }

Property Value

IColorRamp:

The silver color ramp.

Teal

Gets the teal color ramp.

public IColorRamp Teal { get; }

Property Value

IColorRamp:

The teal color ramp.

Yellow

Gets the yellow color ramp.

public IColorRamp Yellow { get; }

Property Value

IColorRamp:

The yellow color ramp.

Methods

GetBaseColorForBrandColor(ThemeIntent, Color)

Researches the color family base Color that will generate a Color closest to the specified brand/accent color.

public static Color GetBaseColorForBrandColor(ThemeIntent intent, Color brandColor)
Parameter Type Description
intent ThemeIntent

The theme indent.

brandColor Color

The brand/accent Color.

Returns

Color:

The color family base Color that was found.

GetColorRamp(ColorFamilyName)

Returns the IColorRamp for the specified color family.

public IColorRamp GetColorRamp(ColorFamilyName familyName)
Parameter Type Description
familyName ColorFamilyName

A ColorFamilyName indicating the color family.

Returns

IColorRamp:

The IColorRamp for the specified color family.

Inherited Members