ChartSeriesLegendItemLineSettingsBuilder
Methods
Color(System.String)
The color of the legend item of type line. Accepts a valid CSS color string, including HEX and RGB. Defaults to the series color.
Parameters
value - System.String
The value for Color
Example
Razor
@(Html.Kendo().Chart()
.Name("chart")
.Series(series =>
{
series.Column(model => model.UnitPrice).Name("Unit Price").LegendItem(legendItem => legendItem.Line(line => line.Color("red")));
})
)
DashType(Kendo.Mvc.UI.ChartDashType)
The dash type of the legend item of type line.The following dash types are supported: "dash" - a line consisting of dashes; "dashDot" - a line consisting of a repeating pattern of dash-dot; "dot" - a line consisting of dots; "longDash" - a line consisting of a repeating pattern of long-dash; "longDashDot" - a line consisting of a repeating pattern of long-dash-dot; "longDashDotDot" - a line consisting of a repeating pattern of long-dash-dot-dot or "solid" - a solid line.
Parameters
value - ChartDashType
The value for DashType
Example
Razor
@(Html.Kendo().Chart()
.Name("chart")
.Series(series =>
{
series.Column(model => model.UnitPrice).Name("Unit Price").LegendItem(legendItem => legendItem.Line(line => line.DashType(ChartDashType.LongDash)));
})
)
Opacity(System.Double)
The opacity of the legend item of type line. Defaults to the series opacity.
Parameters
value - System.Double
The value for Opacity
Example
Razor
@(Html.Kendo().Chart()
.Name("chart")
.Series(series =>
{
series.Column(model => model.UnitPrice).Name("Unit Price").LegendItem(legendItem => legendItem.Line(line => line.Opacity(0.5)));
})
)