Class ChartCrosshairTextStyle
Provides options to customize the tooltip text style of the crosshair tooltip.
Inheritance
Implements
Inherited Members
Namespace: Syncfusion.Blazor.Toolkit.Charts
Assembly: Syncfusion.Blazor.Toolkit.dll
Syntax
public class ChartCrosshairTextStyle : ChartDefaultFont, IAsyncDisposable, ISubcomponentTracker, IChartDefaultFont
Constructors
ChartCrosshairTextStyle()
Declaration
public ChartCrosshairTextStyle()
Properties
Color
Gets or sets the color for the crosshair tooltip text.
Declaration
public override string Color { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String | A CSS color string. The default is theme-dependent. For Fluent, the default is rgba(249, 250, 251, 1). |
Overrides
Remarks
Accepts any valid CSS color (e.g., #fff, rgba(255,255,255,0.9)).
Examples
<ChartPrimaryXAxis>
<ChartAxisCrosshairTooltip Enable="true">
<ChartCrosshairTextStyle Color="blue" />
</ChartAxisCrosshairTooltip>
</ChartPrimaryXAxis>
FontFamily
Gets or sets the font family for the crosshair tooltip text.
Declaration
public override string FontFamily { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String | A string representing the font family. The default is theme-dependent (e.g., Roboto for Fluent). |
Overrides
Remarks
Use this to align with organizational typography guidelines.
Examples
<ChartPrimaryXAxis>
<ChartAxisCrosshairTooltip Enable="true">
<ChartCrosshairTextStyle FontFamily="Arial" />
</ChartAxisCrosshairTooltip>
</ChartPrimaryXAxis>
FontWeight
Gets or sets the font weight for the crosshair tooltip text.
Declaration
public override string FontWeight { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String | A string representing the font weight (e.g., |
Overrides
Remarks
Heavier weights draw greater attention to the tooltip content.
Examples
<ChartPrimaryXAxis>
<ChartAxisCrosshairTooltip Enable="true">
<ChartCrosshairTextStyle FontWeight="bold" />
</ChartAxisCrosshairTooltip>
</ChartPrimaryXAxis>
Size
Gets or sets the font size for the crosshair tooltip text.
Declaration
public override string Size { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String | A string representing the font size (e.g., |
Overrides
Remarks
Adjust to ensure readability on different display densities.
Examples
<ChartPrimaryXAxis>
<ChartAxisCrosshairTooltip Enable="true">
<ChartCrosshairTextStyle Size="15px" />
</ChartAxisCrosshairTooltip>
</ChartPrimaryXAxis>