Class ChartStriplineTooltipBorder
Provides options to customize the border of the stripline tooltip in the SfChart component.
Inheritance
Inherited Members
Namespace: Syncfusion.Blazor.Charts
Assembly: Syncfusion.Blazor.dll
Syntax
public class ChartStriplineTooltipBorder : ChartDefaultBorder, IComponent, IHandleEvent, IHandleAfterRender, IDisposable
Remarks
Use ChartStriplineTooltipBorder to configure the tooltip border appearance for a ChartStripline.
When the width is 0 or the color is not specified, the tooltip may render without a visible border based on the active theme.
Examples
The following example demonstrates how to apply a custom border to a stripline tooltip.
@using Syncfusion.Blazor.Charts
<SfChart>
<ChartPrimaryXAxis ValueType="Syncfusion.Blazor.Charts.ValueType.Category">
<ChartStriplines>
<ChartStripline Start="20" End="25" Color="red">
<ChartStriplineTooltip Enable="true">
<ChartStriplineTooltipBorder Width="2" Color="#D32F2F" />
</ChartStriplineTooltip>
</ChartStripline>
</ChartStriplines>
</ChartPrimaryXAxis>
</SfChart>
Constructors
ChartStriplineTooltipBorder()
Declaration
public ChartStriplineTooltipBorder()
Properties
Color
Gets or sets the border color for the stripline tooltip.
Declaration
[Parameter]
public override string Color { get; set; }
Property Value
| Type | Description |
|---|---|
| string | A string representing the tooltip border color. The default value is |
Overrides
Remarks
Accepts valid CSS color values (hex, rgb/rgba, hsl/hsla, or named colors). Set this property along with a non-zero Width to render a visible border.
Examples
<SfChart>
<ChartPrimaryXAxis ValueType="Syncfusion.Blazor.Charts.ValueType.Category">
<ChartStriplines>
<ChartStripline Start="20" End="25" Color="red">
<ChartStriplineTooltip Enable="true">
<ChartStriplineTooltipBorder Width="1" Color="#D32F2F" />
</ChartStriplineTooltip>
</ChartStripline>
</ChartStriplines>
</ChartPrimaryXAxis>
</SfChart>
Width
Gets or sets the border width for the stripline tooltip.
Declaration
[Parameter]
public override double Width { get; set; }
Property Value
| Type | Description |
|---|---|
| double | A double representing the width of the tooltip border, in pixels. The default value is |
Overrides
Remarks
Increase the value to emphasize the tooltip boundary. A value of 0 results in no visible border.
Examples
<SfChart>
<ChartPrimaryXAxis ValueType="Syncfusion.Blazor.Charts.ValueType.Category">
<ChartStriplines>
<ChartStripline Start="20" End="25" Color="red">
<ChartStriplineTooltip Enable="true">
<ChartStriplineTooltipBorder Width="1" />
</ChartStriplineTooltip>
</ChartStripline>
</ChartStriplines>
</ChartPrimaryXAxis>
</SfChart>
Methods
OnInitialized()
Initializes the stripline tooltip border component and registers it with the parent tooltip element.
Declaration
protected override void OnInitialized()
Overrides
OnParametersSet()
Handles parameter change events and updates the parent tooltip with modified border styling properties.
Declaration
protected override void OnParametersSet()