Line Element
Reference External Link
Line elements are used to represent the line in a line chart.
Namespace:
options.elements.line
.Options(o => o
.Elements(e => e
.Line().Tension(0.2).Fill(true)))Base Element Settings
BackgroundColor
Fill color.
.BackgroundColor("blue").BackgroundColors("rgba(255, 99, 132, 0.2)", "rgba(255, 159, 64, 0.2)")BorderWidth
Stroke width.
.BorderWidth(1)BorderColor
Stroke color.
.BorderColor("grey").BorderColors("yellow", "blue")Line Element Settings
Tension
Bézier curve tension (0 for no Bézier curves).
.Tension(0.4)BorderCapStyle
Line cap style. Default 'butt'. External Link
.BorderCapStyle(CapStyle.Round)BorderDash
Line dash. External Link
.BorderDash(5, 15, 25)BorderDashOffset
Line dash offset. Default 0.0 External Link
.BorderDashOffset(0.1)BorderJoinStyle
Line join style. Default 'miter' External Link
.BorderJoinStyle(JoinStyle.Bevel)CapBezierPoints
true to keep Bézier control inside the chart, false for no restriction. Default true
.CapBezierPoints(true)CubicInterpolationMode
Interpolation mode to apply. Default 'default' External Link
.CubicInterpolationMode("monotone")Fill
How to fill the area under the line. Default false External Link
.Fill(true).Fill("origin")Stepped
true to show the line as a stepped line (tension will be ignored). Default false
.Stepped(true)