In This Article

ColorRamp Class

Represents a color ramp that contains multiple color shades.

public class ColorRamp
Inheritance:
object object

Constructors

ColorRamp(Hue)

Initializes an instance of the class with a Hue.

public ColorRamp(Hue hue)
Parameter Type Description
hue Hue

The Hue whose name will be the ramp name.

ColorRamp(string, bool)

Initializes an instance of the class with a color family name.

public ColorRamp(string name, bool isNeutral)
Parameter Type Description
name string

The ramp name, which is often the color family name (e.g., "Blue") associated with the ramp.

isNeutral bool

Whether the color ramp is for neutral (e.g., grayscale) colors.

Properties

IsNeutral

Whether the color ramp is for neutral (e.g., grayscale) colors.

public bool IsNeutral { get; }

Property Value

bool:

true if the color ramp is for neutral (e.g., grayscale) colors; otherwise, false if the color ramp is for colorful saturated colors.

Name

The ramp name, which is often the color family name (e.g., "Blue") associated with the ramp.

public string Name { get; }

Property Value

string:

The ramp name, which is often the color family name (e.g., "Blue") associated with the ramp.

Shades

Gets the collection of shades in the color ramp.

public ColorRampShadeCollection Shades { get; }

Property Value

ColorRampShadeCollection:

The collection of shades in the color ramp.

Methods

ToString()

Returns the string representation of this object.

public override string ToString()

Returns

string:

The string representation of this object.

Fields

NeutralName

The default name for a color ramp consisting of neutral (e.g., grayscale) colors.

public const string NeutralName = "Neutral"

Inherited Members

Extension Methods