Class ChartStripline
Provides options to customize the striplines of the axis.
Inherited Members
Namespace: Syncfusion.Blazor.Charts
Assembly: Syncfusion.Blazor.dll
Syntax
public class ChartStripline : ChartSubComponent, ISubcomponentTracker, IChartElement
Remarks
This class provides various properties to define the appearance and behavior of striplines in a chart axis, such as color, size, and text alignment.
Constructors
ChartStripline()
Declaration
public ChartStripline()
Properties
Border
Gets or sets an instance of ChartStriplineBorder that defines the border of the strip line.
Declaration
public ChartStriplineBorder Border { get; set; }
Property Value
Type | Description |
---|---|
ChartStriplineBorder | The default value is a instance of ChartStriplineBorder. |
Remarks
This property can be used to customize the color and width of the stripline border.
Color
Gets or sets the color of the strip line.
Declaration
public string Color { get; set; }
Property Value
Type | Description |
---|---|
System.String | A string representing the color of the strip line. The default value is |
Remarks
Use valid hex or rgba CSS color strings for the color value.
DashArray
Gets or sets the dash array of the strip line.
Declaration
public string DashArray { get; set; }
Property Value
Type | Description |
---|---|
System.String | A string representing the dash array of the strip line. The default value is |
Remarks
The default value is null
, indicating no specific dash array is set by default.
End
Gets or sets the end value of the strip line.
Declaration
public object End { get; set; }
Property Value
Type | Description |
---|---|
System.Object | An object representing the end value of the strip line. The default value is |
Remarks
This property type is an object; based on the axis type, the value will be assigned.
HorizontalAlignment
Defines the position of the strip line text horizontally.
Declaration
public Anchor HorizontalAlignment { get; set; }
Property Value
Type | Description |
---|---|
Anchor | One of the Anchor enumerations that specifies the strip line text position. The options include:
|
Remarks
This property determines where the strip line text will be horizontally positioned relative to the strip line.
IsRepeat
Gets or sets a value that specifies whether the strip line should be repeated.
Declaration
public bool IsRepeat { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | true if the strip line should be repeated; otherwise, false. The default value is false. |
Remarks
When set to true, the strip line will be drawn repeatedly across the axis. If set to false, only a single strip line will be displayed.
IsSegmented
Gets or sets a value indicating whether the strip line is segmented.
Declaration
public bool IsSegmented { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | true if the strip line is segmented; otherwise, false. The default value is false. |
Remarks
If set to true, stripline can be created in a specific region as a segment.
Opacity
Gets or sets the opacity of the strip line.
Declaration
public double Opacity { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The double representing the opacity of the strip line. The default value is 1. |
Remarks
It accepts values from 0 to 1.
RepeatEvery
Gets or sets a value that specifies the interval based on the axis value for repeating stripline.
Declaration
public object RepeatEvery { get; set; }
Property Value
Type | Description |
---|---|
System.Object | An object representing the interval for repeating the stripline based on the axis value. The default value is null. |
Remarks
RepeatUntil
Gets or sets a value that specifies the limit based on the axis value for repeating stripline.
Declaration
public object RepeatUntil { get; set; }
Property Value
Type | Description |
---|---|
System.Object | An object representing the limit for repeating the stripline based on the axis value. The default value is null. |
Remarks
Only applicable when IsRepeat is true, SizeType is not set to SizeType.Pixel, and RepeatEvery is not null.
Rotation
Gets or sets the angle to which the strip line text gets rotated.
Declaration
public double Rotation { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The rotation angle for the strip line text.
The default value is |
Remarks
This property allows customization of the text orientation on a strip line by specifying the rotation angle in degrees.
SegmentAxisName
Gets or sets the name of the axis associated with the segment of the strip line.
Declaration
public string SegmentAxisName { get; set; }
Property Value
Type | Description |
---|---|
System.String | A string representing the name of the axis which the strip line segment is associated. The default value is |
Remarks
This property ensures proper alignment and positioning of the strip line with respect to the specified axis in the chart.
SegmentEnd
Gets or sets the end value of the strip line segment.
Declaration
public object SegmentEnd { get; set; }
Property Value
Type | Description |
---|---|
System.Object | The end value of the strip line segment. The default value is null. |
Remarks
This property determines where the segment concludes, providing control over the length and extent of the strip line.
SegmentStart
Gets or sets the start value of the strip line segment.
Declaration
public object SegmentStart { get; set; }
Property Value
Type | Description |
---|---|
System.Object | The start value of the strip line segment. The default value is null. |
Remarks
This property determines where the segment begins, providing control over the length and extent of the strip line.
Size
Gets or sets the size of the strip line based on the Start value and the axis value type.
Declaration
public double Size { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The size of the strip line. This property determines the extent or length of the strip line on the chart. The default value is 0. |
Remarks
For example, if StartFromAxis is set to true, and the Size is 4 on a Category axis, the strip line will be rendered over 4 category values from the origin.
SizeType
Gets or sets the size type of the strip line.
Declaration
public SizeType SizeType { get; set; }
Property Value
Type | Description |
---|---|
SizeType | One of the SizeType enumerations that specifies the unit of strip line size. The options include:
|
Remarks
This property allows for flexible sizing of strip lines in both time-based and pixel-based units.
Start
Gets or sets the start value of the strip line.
Declaration
public object Start { get; set; }
Property Value
Type | Description |
---|---|
System.Object | An object representing the start value of the strip line. The default value is null. |
Remarks
This property determines where the strip line begins along the axis. Based on the axis type, the value will be assigned.
StartFromAxis
Gets or sets a value indicating whether the strip line should be rendered from the axis origin.
Declaration
public bool StartFromAxis { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | true if the strip line should be rendered from the axis origin; otherwise, false. The default value is false. |
Remarks
This property allows you to control whether the strip line starts from the axis origin or from a specified value. If set to true, the stripline will be rendered from the axis origin, ignoring the Start value if provided.
Text
Gets or sets the text for the strip line.
Declaration
public string Text { get; set; }
Property Value
Type | Description |
---|---|
System.String | A string representing the strip line text. The default value is an empty string. |
Remarks
This property is used to assign a label or descriptive text to the strip line, which can enhance the interpretability of charts by providing contextual information directly on the visual elements. If the text is not set, the strip line will appear without a label, maintaining a cleaner visual appearance but potentially lacking descriptive context.
TextStyle
Gets or sets an instance of ChartStriplineTextStyle which defines the stripline text style.
Declaration
public ChartStriplineTextStyle TextStyle { get; set; }
Property Value
Type | Description |
---|---|
ChartStriplineTextStyle | The default value is an instance of ChartStriplineTextStyle. |
Remarks
Use this property to define specific styling attributes such as color and font-properties for the text displayed within the strip line.
VerticalAlignment
Gets or sets a value that specifies the position of the strip line text vertically.
Declaration
public Anchor VerticalAlignment { get; set; }
Property Value
Type | Description |
---|---|
Anchor | One of the Anchor enumerations that specifies the position of the strip line text vertically. The options include:
|
Remarks
This property determines where the strip line text will be vertically positioned relative to the strip line.
Visible
Gets or sets a value indicating whether the strip line for the axis should be visible.
Declaration
public bool Visible { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | true if the strip line for the axis should be visible; otherwise, false. The default value is true. |
Remarks
Use this property to toggle the strip line's visibility based on the specific design and functionality requirements of your application.
ZIndex
Gets or sets the order of the strip line in relation to series elements.
Declaration
public ZIndex ZIndex { get; set; }
Property Value
Type | Description |
---|---|
ZIndex | One of the ZIndex enumerations that specify the order of the strip line. The options include:
|
Remarks
Adjusting the ZIndex is useful when you need to control the visual layering of the strip line relative to other elements in a chart, thereby ensuring the intended elements are visible.
Methods
OnInitialized()
Declaration
protected override void OnInitialized()
OnParametersSet()
Declaration
protected override void OnParametersSet()