Class ChartStackLabelSettingsBuilder
Inheritance
System.Object
Syncfusion.EJ2.ControlBuilder
ChartStackLabelSettingsBuilder
Assembly: Syncfusion.EJ2.dll
Syntax
public class ChartStackLabelSettingsBuilder : ControlBuilder
Constructors
ChartStackLabelSettingsBuilder()
Declaration
public ChartStackLabelSettingsBuilder()
ChartStackLabelSettingsBuilder(ChartStackLabelSettings)
Declaration
public ChartStackLabelSettingsBuilder(ChartStackLabelSettings model)
Parameters
Methods
Angle(Double)
Specifies the rotation angle for the stack labels. This property allows to rotate the stack labels to a specific angle (in degrees).
Declaration
public ChartStackLabelSettingsBuilder Angle(double value)
Parameters
Type |
Name |
Description |
System.Double |
value |
|
Returns
Border(Object)
Configures the border appearance for the stack labels.
For rounded corners to appear, both the rx
and ry
properties must be set, and the border
property should also be configured with a width and color.
Declaration
public ChartStackLabelSettingsBuilder Border(object value)
Parameters
Type |
Name |
Description |
System.Object |
value |
|
Returns
Fill(String)
The background color of the stack labels. Accepts valid CSS color strings, including hex and RGBA values.
Declaration
public ChartStackLabelSettingsBuilder Fill(string value)
Parameters
Type |
Name |
Description |
System.String |
value |
|
Returns
Font(Object)
Customizes the appearance of the stack label text. Options include font size, color, style, weight, and family.
Customizing these properties allows to ensure that the stack labels are legible and match the overall chart design.
Declaration
public ChartStackLabelSettingsBuilder Font(object value)
Parameters
Type |
Name |
Description |
System.Object |
value |
|
Returns
Used to format the stack label text. This property accepts a string that can contain placeholders.
Supports placeholders such as {value}
, where {value}
represents the total stack value.
Declaration
public ChartStackLabelSettingsBuilder Format(string value)
Parameters
Type |
Name |
Description |
System.String |
value |
|
Returns
Margin(Object)
Configures the margin for the stack label. This property allows you to define the spacing around the stack label by specifying the left, right, top, and bottom margins.
Declaration
public ChartStackLabelSettingsBuilder Margin(object value)
Parameters
Type |
Name |
Description |
System.Object |
value |
|
Returns
Rx(Double)
Specifies the rounded corner radius along the X-axis for the stack label background.
It defines how much curvature the corners of the label will have along the X-axis (horizontal direction).
Note: The border
property must be set for rounded corners to be visible.
Declaration
public ChartStackLabelSettingsBuilder Rx(double value)
Parameters
Type |
Name |
Description |
System.Double |
value |
|
Returns
Ry(Double)
Specifies the rounded corner radius along the Y-axis for the stack label background.
It defines the curvature of the stack label's background along the Y-axis (vertical direction).
Note: The border
property must be set for rounded corners to be visible.
Declaration
public ChartStackLabelSettingsBuilder Ry(double value)
Parameters
Type |
Name |
Description |
System.Double |
value |
|
Returns
Visible(Boolean)
Specifies whether the stack labels are visible or not in the chart.
Setting this property to true
will display the stack labels, showing the total value for each stack in stacked charts.
Declaration
public ChartStackLabelSettingsBuilder Visible(bool value)
Parameters
Type |
Name |
Description |
System.Boolean |
value |
|
Returns