Public, safe interface for Panels rendering engine.
Scale for panel area in pixels. Margin should be set according to panel margin (currently constant).
Scale for panel area in percentages (0-100). Margin should be set according to panel margin (currently constant).
Creates range area series for visualization bands of data between the two given lines. Each point in the chart is specified by two y values.
Options to attach series to axes.
Created series
Creates area series for visualization of data between the given line and base line limit.
Options to attach series to axes, a number for comparisons and defines the type of area series.
Created series
Position of X axis. false = bottom, true = top
Custom tick strategy for axis that defines positioning and formating of its ticks. See AxisTickStrategies for a collection of options.
Created Axis
Position of Y axis. false = left, true = right
Custom tick strategy for axis that defines positioning and formating of its ticks. See AxisTickStrategies for a collection of options.
Created Axis
Create Series for visualization of data with quartiles.
Options to attach series to axes, type of StatisticFigure and type of dimensionStrategy.
Created series
Create new XY Chart Marker to be rendered as part of UI.
Optional StaticCursorBuilderXY to customize structure/style of chartMarker. MarkerBuilders.XY can be used to build a custom one from scratch.
Optional arbitrary X axis to attach ChartMarker on
Optional arbitrary Y axis to attach ChartMarker on
Created ChartMarker
Create Series for drawing ellipses.
Options to attach series to axes.
Created series
Creates heatmap intensity series for visualization of magnitude.
Options to attach series to axes, major settings and defines the type of area series.
Created series
Add a stand-alone LegendBox using a builder.
Type of UIElement that is specified by 'builder'-parameter.
LegendBoxBuilder. If omitted, HorizontalLegendBox will be selected. Use LegendBoxBuilders for selection.
Optional custom scale to position LegendBox on. Defaults to whole chart in percentages [0, 100].
LegendBox that fulfills interfaces: UIElementType (typeparam) and UIElement
Create Series for visualization of data by continuous lines.
Options to attach series to axes and define the type of data pattern.
LineSeries.
Create Series for visualization of OHLC segments.
Options to attach series to axes, define type of OHLCFigure used for positive segments, negative segments and series.
Created OHLCSeries whose interface is related to value of 'seriesConstructor' parameter
Create Plot for visualization of data by points and lines
Options to attach series to axes and define the shape for points of series.
Created plot
Create Series for visualization of data by points.
Options to attach series to axes and define the shape for points of series.
Created series.
Create Series for drawing rectangles.
Options to attach series to axes.
Created series
Create Series for visualization of data by individual line-segments
Options to attach series to axes.
Created series
Create Series for visualization of data by points and lines, where the segments between the data points are smoothed.
Options to attach series to axes and define the shape for points of series.
Created series
Create Series for visualization of data by points and lines. Apply steps to the line curve.
Options to attach series to axes and define the shape for points of series, step behavior for StepSeries. Possible values are 'before', 'middle' and 'after', defaults to StepOptions.before.
Created series
Add a stand-alone UIElement using a builder.
Type of UIElement that is specified by 'builder'-parameter.
UIElementBuilder. If omitted, TextBoxBuilder will be selected. Use UIElementBuilders for selection.
Optional custom scale to position UIElement on. Defaults to whole chart in percentages [0, 100].
Object that fulfills interfaces: UIElementType (typeparam) and UIElement
Disable all animations for the chart.
After calling this function, animations (Zooming, scaling) for all Axes will be disabled. Animations must be recreated manually afterwards.
Chart itself for fluent interface.
Permanently dispose the component.
To fully allow Garbage-Collection to free the resources used by the component, make sure to remove any references to the component and its children in application code.
let chart = ...ChartXY()
let axisX = chart.getDefaultAxisX()
// Dispose Chart, and remove all references so that they can be garbage-collected.
chart.dispose()
chart = undefined
axisX = undefined
Object itself for fluent interface
Auto cursor object
Get current mode of charts Auto cursor
Value from enum AutoCursorMode
array of axis positions which have to be included to the output empty array indicates all of positions are included
An array of axis
Get fillstyle of chart background.
FillStyle
Get stroke style of chart background.
LineStyle
Get fillstyle of chart background. This is the area enclosed by the axis'.
FillStyle
/** Get stroke style of chart background. This is the area enclosed by the axis'.
LineStyle
Primary X axis is the bottom one. If there is no bottom axis, the top one became default.
Primary Y axis is the left one. If there is no left axis, the right one became default.
Get fillStyle for fitting rectangle when fitting.
FillStyle
Get stroke style for fitting rectangle when fitting.
LineStyle
Get minimum size of Panel. Depending on the type of class this value might be automatically computed to fit different elements.
Vec2 minimum size or undefined if unimplemented
Get is mouse-interaction enabled: Panning axes by dragging mouse on frame.
Boolean flag
Get is mouse-interaction enabled: Fitting axes by capturing rectangle on frame.
Boolean flag
Get is mouse-interaction enabled: Zooming axes by capturing rectangle on frame.
Boolean flag
Get is mouse-interaction enabled: Zooming axes with mouse-wheel on frame.
Boolean flag
Get if mouse and cursor interactions are disabled during scrolling animations for the chart's series.
True if interactions with series are disabled, false if not.
Get if mouse and cursor interactions are disabled during zooming animations for the chart's series.
True if interactions with series are disabled, false if not.
Get padding around Chart in pixels.
Padding datastructure
Get series of a chart
series
Get text of Chart title.
Chart title as a string.
Get fill style of Chart Title.
FillStyle object
Get font of Chart title.
FontSettings object
Padding after Chart title
Padding before Chart title
Get fillStyle for zooming rectangle when zooming.
FillStyle
Get stroke style for zooming rectangle when zooming.
LineStyle
Remove event listener from resize event.
Token of event listener which has to be removed
True if the listener is successfully removed and false if it is not found
Subscribe to resize event of Panel.
Handler function for event
Token of subscription
Capture rendered state in an image file. Prompts the browser to download the created file.
NOTE: The download might be blocked by browser/plugins as harmful. To prevent this, only call the method in events tied to user-interactions. From mouse-event handlers, for example.
Has two optional parameters which directly reference JavaScript API HTMLCanvasElement.toDataURL. For supported image formats, compression quality, Etc. refer to:
https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toDataURL
Example usage:
Desired result | Arguments |
---|---|
Download 'screenshot.png' | 'screenshot' |
Attempt download 'maybeNotSupported.bmp' | 'maybeNotSupported', 'image/bmp' |
Attempt download jpeg.file with specified compression quality | 'fileName', 'image/jpeg', 0.50 |
Name of prompted download file as string. File extension shouldn't be included as it is automatically detected from 'type'-argument.
A DOMString indicating the image format. The default format type is image/png.
A Number between 0 and 1 indicating the image quality to use for image formats that use lossy compression such as image/jpeg and image/webp. If this argument is anything else, the default value for image quality is used. The default value is 0.92.
Mutator function for charts auto cursor.
Mutator function for a Cursor
Object itself for fluent interface
Set mode of charts Auto cursor
Value from enum AutoCursorMode
Object itself for fluent interface
Set fillStyle of panel background.
FillStyle or function which modifies it
Object itself
Set stroke style of panel background.
LineStyle or function which modifies it
Object itself
Set fillStyle of chart background. This is the area enclosed by the axis'.
FillStyle or mutator to modify existing one
Object itself
Set stroke of chart background. This is the area enclosed by the axis'.
LineStyle or mutator to modify existing one
Object itself
Set fillStyle for zooming rectangle when fitting.
FillStyle or mutator to modify existing one
Object itself
Set stroke style for zooming rectangle when fitting.
LineStyle or mutator to modify existing one
Object itself
Set mouse style when hovering over chart background.
Mouse-style preset name (see MouseStyles)
Object itself
Set mouse style when fitting over chart background.
Mouse-style preset name (see MouseStyles)
Object itself
Set is mouse-interaction enabled: Panning axes by dragging mouse on frame.
Boolean flag
Object itself
Set is mouse-interaction enabled: Fitting axes by capturing rectangle on frame.
Boolean flag
Object itself
Set is mouse-interaction enabled: Zooming axes by capturing rectangle on frame.
Boolean flag
Object itself
Set is mouse-interaction enabled: Zooming axes with mouse-wheel on frame (also touch pinch currently).
Boolean flag
Object itself
Set all mouse-interaction flags at once.
Are mouse-interactions enabled
Object itself
Set if mouse and cursor interactions should be disabled during scrolling animations for the chart's series.
True if mouse and cursor interactions should be disabled during scrolling animations, false if not.
Chart itself for fluent interface.
Set if mouse and cursor interactions should be disabled during zooming animations for the chart's series.
True if mouse and cursor interactions should be disabled during zooming animations, false if not.
Chart itself for fluent interface.
Set mouse style when panning over chart background.
Mouse-style preset name (see MouseStyles)
Object itself
Set mouse style when zooming over chart background.
Mouse-style preset name (see MouseStyles)
Object itself
Set padding around Chart in pixels.
Number with pixel margins for all sides or datastructure with individual pixel paddings for each side. Any side can be omitted, only passed values will be overridden.
Object itself
Set text of Chart title.
Chart title as a string.
Object itself for fluent interface.
Set fill style of Chart Title.
Example usage:
Desired result | Argument |
---|---|
Specified FillStyle | new SolidFill({ color: ColorHEX('#F00') }) |
Changed transparency | (solidFill) => solidFill.setA(80) |
Hidden | emptyFill |
Either a FillStyle object or a function, which will be used to create a new FillStyle based on current value.
Chart itself
Set font of Chart Title.
Example usage:
Desired result | Argument |
---|---|
Specified FontSettings | new FontSettings({ size: 24, style: 'italic' }) |
Set to bold | (fontSettings) => fontSettings.setWeight('bold') |
Either a FontSettings object or a function, which will be used to create a new FontSettings based on current value.
Chart itself
Specifies padding after chart title.
This does not have an effect if title is hidden (empty FillStyle).
Gap after the chart title in pixels.
Chart itself for fluent interface
Specifies padding before chart title.
This does not have an effect if title is hidden (empty FillStyle).
Gap between the top of chart and its title in pixels.
Chart itself for fluent interface
Set fillStyle for zooming rectangle when zooming.
FillStyle or mutator to modify existing one
Object itself
Set stroke style for zooming rectangle when zooming.
LineStyle or mutator to modify existing one
Object itself
Solves the nearest data-point from series inside Chart of a given coordinate on screen
Location on screen or omit for cur mouse location
Undefined or data-structure for positioning of markers (and cursors)
Chart for visualizing data using the Cartesian coordinate system, across any number of Axes. It has a multitude of methods for adding various types of Series.
Charts are created by methods of LightningChart interface or a Dashboard.
The Axes of a ChartXY* can be manipulated with a variety of methods: