Skip to main content

SimpleLineChart

The SimpleLineChart widget is a lightweight line chart that plots a list of numbers as a connected line to visualize a trend.
Use it to show movement at a glance, such as a stock price or a changing metric.

Definition and role

The SimpleLineChart widget takes a list of data values (dataList) and draws a line that connects each value as a point. Render it as straight segments or as a smooth spline curve. It also supports filling the area under the line, highlighting the minimum and maximum points, and an entrance animation.

  • Category: Contents
  • Palette item name: SimpleLine
  • Default size: 300 wide × 150 tall
  • With no data, the editor shows a placeholder box labeled SimpleLineChart.

Features

FeatureDescription
Line drawingConnects the values in dataList into a line. Set its color and thickness with lineColor and lineWidth.
Curve or straightTurn on isSpline for a smooth curve, or leave it off for straight segments. (A curve needs 4 or more points.)
Area fillSet areaColor or areaGradient to fill the area under the line.
Min and max markersTurn on showMinMax to mark the lowest and highest data points with a dot and text (minText, maxText).
Entrance animationTurn on useAnimation and the graph unfolds from a horizontal center line.
Range and insetsSet the vertical axis range with min and max, and the top and bottom insets with topInset and bottomInset.

How to use

  1. Open the Contents category in the left widget palette.
  2. Drag and drop the SimpleLine item onto the canvas.
  3. In the properties panel on the right, enter the numbers to plot in dataList.
  4. Adjust the line with lineColor, lineWidth, and isSpline as needed.
  5. Turn on highlights and animation with showMinMax and useAnimation.

Properties

PropertyDescriptionDefaultValue / type
dataListList of numbers to plot. Each value becomes one point on the line.Empty listList of numbers
useAnimationWhether to play the entrance animationfalsetrue / false
showMinMaxWhether to highlight the minimum and maximum pointsfalsetrue / false
minTextText shown at the minimum pointNot setString
minColorColor of the dot and text at the minimum pointNot set (shown in blue)Color
maxTextText shown at the maximum pointNot setString
maxColorColor of the dot and text at the maximum pointNot set (shown in red)Color
isSplineWhether to draw a spline curvefalsetrue / false
lineWidthLine thickness1.0Number (0.1~10.0)
lineColorLine color#FF0000 (red)Color
lineGradientGradient applied to the line — used instead of lineColor when setNot setGradient
areaColorFill color for the area under the lineNot setColor
areaGradientFill gradient for the area under the lineNot setGradient
topInsetTop inset, as a % of the chart heightNot setNumber (0~100)
bottomInsetBottom inset, as a % of the chart heightNot setNumber (0~100)
minLowest value on the vertical axis — falls back to the lowest data value when unsetNot setNumber
maxHighest value on the vertical axis — falls back to the highest data value when unsetNot setNumber

Notes and tips

warning

When dataList is empty, no line is drawn. The editor shows only the SimpleLineChart placeholder box.

tip

Leave min and max unset and the vertical axis adjusts automatically to the lowest and highest data values. An isSpline curve only applies with 4 or more points — with fewer, the chart draws straight segments.

Learn more

tip

For the full set of Widget Controls (Property, Method, and Event) for scripting this widget, visit SimpleLineChart Widget Control.