# ChartStateCategory

Describes one categorical state, such as an operational state or a severity: the key that data refers to, its display label, its colour, and how its marks are…

 Class  

`ChartForgeX.Core`

**Namespace**

`ChartForgeX.Core`

**Assembly**

`ChartForgeX`

**Source**

[ChartStateCategory.cs:17](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartStateCategory.cs#L17)

**Modifiers**

sealed

Describes one categorical state, such as an operational state or a severity: the key that data refers to, its display label, its colour, and how its marks are drawn. Categories are listed in legends in the order they are registered.

## Inheritance

- object
- ChartStateCategory

## Usage

 Explore 9 API references to this type 

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Returned or exposed by 4

- Property [ChartStateTimelineOptions.Categories](/api/chartforgex-core-chartstatetimelineoptions/#property-categories)
- Method [VisualStatusTokens.OperationalStateCategories](/api/chartforgex-themes-visualstatustokens/#method-operationalstatecategories-collections-generic-ireadonlydictionary-system-string-system-string)
- Method [VisualStatusTokens.OutcomeCategories](/api/chartforgex-themes-visualstatustokens/#method-outcomecategories-collections-generic-ireadonlydictionary-system-string-system-string)
- Method [VisualStatusTokens.SeverityCategories](/api/chartforgex-themes-visualstatustokens/#method-severitycategories-collections-generic-ireadonlydictionary-system-string-system-string)

### Accepted by parameters 5

- Method [Chart.StateCategories](/api/chartforgex-core-chart/#method-statecategories-collections-generic-ienumerable-chartforgex-core-chartstatecategory) parameter `states`
- Extension method [ChartStateTimelineOptions.Categories](/api/chartforgex-core-chartstatetimelineoptions/#extension-categories-chartforgex-core-chartstatetimelineoptions-collections-generic-ienumerable-chartforgex-core-chartstatecategory) parameter `items`
- Extension method [ChartStateTimelineOptions.Category](/api/chartforgex-core-chartstatetimelineoptions/#extension-category-chartforgex-core-chartstatetimelineoptions-chartforgex-core-chartstatecategory) parameter `item`
- Method [ChartStateTimelineOptionsFluent.Categories](/api/chartforgex-core-chartstatetimelineoptionsfluent/#method-categories-chartforgex-core-chartstatetimelineoptions-collections-generic-ienumerable-chartforgex-core-chartstatecategory) parameter `items`
- Method [ChartStateTimelineOptionsFluent.Category](/api/chartforgex-core-chartstatetimelineoptionsfluent/#method-category-chartforgex-core-chartstatetimelineoptions-chartforgex-core-chartstatecategory) parameter `item`

 Filter members   

    Show inherited   

 

## Constructors

 `public ChartStateCategory(string key, string label, ChartColor color, ChartStatePattern pattern = Solid, ChartStateEmphasis emphasis = Normal)` [#](#constructor-ctor-string-string-chartforgex-primitives-chartcolor-chartforgex-core-chartstatepattern-chartforgex-core-chartstateemphasis) 

[ChartStateCategory.cs:17](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartStateCategory.cs#L17)

Initializes a new state definition.

Parameters

**key string required**

The state key used by segments, for example up or degraded.

**label string required**

The display label shown in the legend and tooltips.

**color ChartForgeX.Primitives.ChartColor required**

The colour of marks in this state.

**pattern ChartForgeX.Core.ChartStatePattern = Solid optional**

How marks are filled: solid, hatched, cross-hatched, or outlined.

**emphasis ChartForgeX.Core.ChartStateEmphasis = Normal optional**

How much marks draw the eye; [ChartStateEmphasis.Quiet](/api/chartforgex-core-chartstateemphasis/) lightens them.

## Inherited Methods

 `public virtual bool Equals(object? obj)` [#](#method-equals-object) 

Inherited from object

Parameters

**obj object? required**

Returns

 `bool` 

 `public virtual int GetHashCode()` [#](#method-gethashcode) 

Inherited from object

Returns

 `int` 

 `public Type GetType()` [#](#method-gettype) 

Inherited from object

Returns

 `Type` 

 `public virtual string? ToString()` [#](#method-tostring) 

Inherited from object

Returns

 `string?` 

## Properties

 `public string Key { get; }` [#](#property-key) 

[ChartStateCategory.cs:29](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartStateCategory.cs#L29)

Gets the state key used by segments.

 `public string Label { get; }` [#](#property-label) 

[ChartStateCategory.cs:32](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartStateCategory.cs#L32)

Gets the display label shown in the legend and tooltips.

 `public ChartColor Color { get; }` [#](#property-color) 

[ChartStateCategory.cs:35](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartStateCategory.cs#L35)

Gets the colour of marks in this state.

 `public ChartStatePattern Pattern { get; }` [#](#property-pattern) 

[ChartStateCategory.cs:38](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartStateCategory.cs#L38)

Gets how marks in this state are filled.

 `public ChartStateEmphasis Emphasis { get; }` [#](#property-emphasis) 

[ChartStateCategory.cs:41](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartStateCategory.cs#L41)

Gets how much marks in this state draw the eye.

<!-- PowerForge markdown artifact sha256:F46D3577365888C75077E968ADEC486839D7659CF5F7E095A3A327178741CB0C -->
