# ChartTextRole

Defines the text role styled by a chart text style.

 Enum  

`ChartForgeX.Core`

**Namespace**

`ChartForgeX.Core`

**Assembly**

`ChartForgeX`

**Source**

[ChartTextRole.cs:6](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartTextRole.cs#L6)

**Base**

`Enum`

**Implements**

 `IComparable` `ISpanFormattable` `IFormattable` `IConvertible` 

**Modifiers**

sealed

Defines the text role styled by a chart text style.

## Inheritance

- Enum
- ChartTextRole

## 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 7

- Field [ChartTextRole.AxisTitle](/api/chartforgex-core-charttextrole/#field-axistitle)
- Field [ChartTextRole.DataLabel](/api/chartforgex-core-charttextrole/#field-datalabel)
- Field [ChartTextRole.Legend](/api/chartforgex-core-charttextrole/#field-legend)
- Field [ChartTextRole.Subtitle](/api/chartforgex-core-charttextrole/#field-subtitle)
- Field [ChartTextRole.TickLabel](/api/chartforgex-core-charttextrole/#field-ticklabel)
- Field [ChartTextRole.Title](/api/chartforgex-core-charttextrole/#field-title)
- Property [VisualArtifactInterchangeWaterfallArtifact.TextStyles](/api/chartforgex-visualartifacts-visualartifactinterchangewaterfallartifact/#property-textstyles)

### Accepted by parameters 2

- Method [Chart.TextStyle](/api/chartforgex-core-chart/#method-textstyle-chartforgex-core-charttextrole-action-chartforgex-typography-textstyleoverride) parameter `role`
- Method [ChartOptions.GetTextStyle](/api/chartforgex-core-chartoptions/#method-gettextstyle-chartforgex-core-charttextrole) parameter `role`

 Filter members   

    Show inherited   

 

## Inherited Methods

 `public int CompareTo(object? target)` [#](#method-compareto-object) 

Inherited from Enum

Parameters

**target object? required**

Returns

 `int` 

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

Inherited from Enum

Parameters

**obj object? required**

Returns

 `bool` 

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

Inherited from Enum

Returns

 `int` 

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

Inherited from object

Returns

 `Type` 

 `public TypeCode GetTypeCode()` [#](#method-gettypecode) 

Inherited from Enum

Returns

 `TypeCode` 

 `public bool HasFlag(Enum flag)` [#](#method-hasflag-enum) 

Inherited from Enum

Parameters

**flag Enum required**

Returns

 `bool` 

 ToString 4 overloads 

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

Inherited from Enum

Returns

 `string` 

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

Inherited from Enum

Parameters

**format string? required**

Returns

 `string` 

 `public string ToString(IFormatProvider? provider)` [#](#method-tostring-iformatprovider) 

Inherited from Enum

 `Obsolete("The provider argument is not used. Use ToString() instead.")` 

Parameters

**provider IFormatProvider? required**

Returns

 `string` 

 `public string ToString(string? format, IFormatProvider? provider)` [#](#method-tostring-string-iformatprovider) 

Inherited from Enum

 `Obsolete("The provider argument is not used. Use ToString(String) instead.")` 

Parameters

**format string? required**

**provider IFormatProvider? required**

Returns

 `string` 

## Values

 `public const ChartTextRole Title` [#](#field-title) 

[ChartTextRole.cs:8](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartTextRole.cs#L8)

Styles the chart title.

Value: `0`

 `public const ChartTextRole Subtitle` [#](#field-subtitle) 

[ChartTextRole.cs:10](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartTextRole.cs#L10)

Styles the chart subtitle.

Value: `1`

 `public const ChartTextRole AxisTitle` [#](#field-axistitle) 

[ChartTextRole.cs:12](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartTextRole.cs#L12)

Styles x-axis, y-axis, and secondary-axis titles.

Value: `2`

 `public const ChartTextRole TickLabel` [#](#field-ticklabel) 

[ChartTextRole.cs:14](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartTextRole.cs#L14)

Styles axis tick and category labels.

Value: `3`

 `public const ChartTextRole Legend` [#](#field-legend) 

[ChartTextRole.cs:16](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartTextRole.cs#L16)

Styles legend labels.

Value: `4`

 `public const ChartTextRole DataLabel` [#](#field-datalabel) 

[ChartTextRole.cs:18](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Core/ChartTextRole.cs#L18)

Styles data labels rendered inside or near marks.

Value: `5`

<!-- PowerForge markdown artifact sha256:592ED6D6C152E73E8904E087766BBBBE41C233299A1CAADF22AA446C6AD7143F -->
