scichart 2.1.2294 → 2.2.2378
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Builder/buildAxis.d.ts +7 -0
- package/Builder/buildAxis.js +6 -0
- package/Builder/buildDataSeries.d.ts +19 -1
- package/Builder/buildDataSeries.js +22 -1
- package/Builder/buildModifiers.d.ts +2 -1
- package/Builder/buildSeries.d.ts +7 -2
- package/Builder/buildSeries.js +5 -1
- package/Charting/ChartModifiers/CursorModifier.d.ts +5 -0
- package/Charting/ChartModifiers/CursorModifier.js +15 -10
- package/Charting/ChartModifiers/LegendModifier.d.ts +31 -0
- package/Charting/ChartModifiers/LegendModifier.js +22 -0
- package/Charting/ChartModifiers/RolloverModifier.d.ts +10 -0
- package/Charting/ChartModifiers/RolloverModifier.js +76 -19
- package/Charting/Drawing/WebGlRenderContext2D.js +26 -42
- package/Charting/LayoutManager/LayoutManager.js +6 -1
- package/Charting/Model/BaseHeatmapDataSeries.d.ts +3 -2
- package/Charting/Model/BaseHeatmapDataSeries.js +17 -5
- package/Charting/Model/ChartData/HlcSeriesInfo.d.ts +12 -0
- package/Charting/Model/ChartData/HlcSeriesInfo.js +52 -0
- package/Charting/Model/Filters/HlcCustomFilter.d.ts +41 -0
- package/Charting/Model/Filters/HlcCustomFilter.js +119 -0
- package/Charting/Model/Filters/HlcFilterBase.d.ts +30 -0
- package/Charting/Model/Filters/HlcFilterBase.js +141 -0
- package/Charting/Model/Filters/HlcScaleOffsetFilter.d.ts +18 -0
- package/Charting/Model/Filters/HlcScaleOffsetFilter.js +86 -0
- package/Charting/Model/Filters/XyFilterBase.d.ts +2 -0
- package/Charting/Model/Filters/XyFilterBase.js +6 -0
- package/Charting/Model/Filters/XyyFilterBase.js +9 -0
- package/Charting/Model/Filters/XyzFilterBase.js +12 -3
- package/Charting/Model/HlcDataSeries.d.ts +189 -0
- package/Charting/Model/HlcDataSeries.js +557 -0
- package/Charting/Model/IDataSeries.d.ts +5 -1
- package/Charting/Model/IDataSeries.js +4 -0
- package/Charting/Model/PointSeries/BasePointSeriesWrapped.d.ts +1 -1
- package/Charting/Model/PointSeries/BasePointSeriesWrapped.js +2 -2
- package/Charting/Model/PointSeries/HlcPointSeriesWrapped.d.ts +10 -0
- package/Charting/Model/PointSeries/HlcPointSeriesWrapped.js +31 -0
- package/Charting/Model/PointSeries/IPointSeries.d.ts +5 -0
- package/Charting/Model/PointSeries/XyyPointSeriesWrapped.d.ts +1 -1
- package/Charting/Model/PointSeries/XyyPointSeriesWrapped.js +3 -3
- package/Charting/Numerics/CoordinateCalculators/LogarithmicCoordinateCalculator.d.ts +2 -2
- package/Charting/Numerics/CoordinateCalculators/LogarithmicCoordinateCalculator.js +15 -6
- package/Charting/Services/SciChartRenderer.d.ts +1 -0
- package/Charting/Services/SciChartRenderer.js +6 -0
- package/Charting/Visuals/Annotations/AnnotationBase.d.ts +6 -1
- package/Charting/Visuals/Annotations/AnnotationBase.js +23 -2
- package/Charting/Visuals/Annotations/CursorTooltipSvgAnnotation.d.ts +6 -0
- package/Charting/Visuals/Annotations/CursorTooltipSvgAnnotation.js +46 -5
- package/Charting/Visuals/Annotations/CustomAnnotation.d.ts +3 -1
- package/Charting/Visuals/Annotations/CustomAnnotation.js +14 -3
- package/Charting/Visuals/Annotations/HorizontalLineAnnotation.d.ts +4 -0
- package/Charting/Visuals/Annotations/HorizontalLineAnnotation.js +3 -2
- package/Charting/Visuals/Annotations/RolloverLegendSvgAnnotation.d.ts +1 -1
- package/Charting/Visuals/Annotations/RolloverLegendSvgAnnotation.js +13 -3
- package/Charting/Visuals/Annotations/RolloverTooltipSvgAnnotation.d.ts +13 -0
- package/Charting/Visuals/Annotations/RolloverTooltipSvgAnnotation.js +71 -14
- package/Charting/Visuals/Annotations/VerticalLineAnnotation.d.ts +2 -0
- package/Charting/Visuals/Annotations/VerticalLineAnnotation.js +3 -2
- package/Charting/Visuals/Annotations/constants.d.ts +2 -1
- package/Charting/Visuals/Annotations/constants.js +1 -0
- package/Charting/Visuals/Axis/AxisBase2D.d.ts +11 -1
- package/Charting/Visuals/Axis/AxisBase2D.js +75 -17
- package/Charting/Visuals/Axis/AxisCore.d.ts +4 -0
- package/Charting/Visuals/Axis/AxisCore.js +6 -0
- package/Charting/Visuals/Axis/AxisRenderer.js +6 -10
- package/Charting/Visuals/Axis/DateTimeNumericAxis.d.ts +11 -0
- package/Charting/Visuals/Axis/DateTimeNumericAxis.js +36 -0
- package/Charting/Visuals/Axis/DeltaCalculator/DateTimeDeltaCalculator.d.ts +28 -0
- package/Charting/Visuals/Axis/DeltaCalculator/DateTimeDeltaCalculator.js +125 -0
- package/Charting/Visuals/Axis/LabelProvider/PieLabelProvider.d.ts +34 -0
- package/Charting/Visuals/Axis/LabelProvider/PieLabelProvider.js +82 -0
- package/Charting/Visuals/Axis/LabelProvider/SmartDateLabelProvider.d.ts +2 -2
- package/Charting/Visuals/Axis/LabelProvider/SmartDateLabelProvider.js +39 -6
- package/Charting/Visuals/Axis/LogarithmicAxis.d.ts +1 -0
- package/Charting/Visuals/Axis/LogarithmicAxis.js +5 -3
- package/Charting/Visuals/Helpers/NativeObject.d.ts +13 -0
- package/Charting/Visuals/Helpers/NativeObject.js +101 -0
- package/Charting/Visuals/Helpers/createNativeRect.d.ts +2 -2
- package/Charting/Visuals/Helpers/createNativeRect.js +3 -1
- package/Charting/Visuals/Helpers/drawBorder.js +2 -2
- package/Charting/Visuals/Helpers/drawLabel.d.ts +3 -3
- package/Charting/Visuals/Helpers/drawLabel.js +38 -18
- package/Charting/Visuals/I2DSurfaceOptions.d.ts +6 -0
- package/Charting/Visuals/Legend/SciChartLegend.d.ts +4 -0
- package/Charting/Visuals/Legend/SciChartLegend.js +7 -1
- package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.d.ts +24 -8
- package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.js +109 -31
- package/Charting/Visuals/RenderableSeries/BaseStackedCollection.d.ts +3 -0
- package/Charting/Visuals/RenderableSeries/BaseStackedCollection.js +8 -0
- package/Charting/Visuals/RenderableSeries/BaseStackedRenderableSeries.d.ts +17 -166
- package/Charting/Visuals/RenderableSeries/BaseStackedRenderableSeries.js +35 -328
- package/Charting/Visuals/RenderableSeries/DrawingProviders/BandSeriesDrawingProvider.d.ts +5 -2
- package/Charting/Visuals/RenderableSeries/DrawingProviders/BandSeriesDrawingProvider.js +5 -3
- package/Charting/Visuals/RenderableSeries/DrawingProviders/BaseSeriesDrawingProvider.js +14 -11
- package/Charting/Visuals/RenderableSeries/DrawingProviders/ErrorSeriesDrawingProvider.d.ts +46 -0
- package/Charting/Visuals/RenderableSeries/DrawingProviders/ErrorSeriesDrawingProvider.js +252 -0
- package/Charting/Visuals/RenderableSeries/DrawingProviders/UniformHeatmapDrawingProvider.js +1 -1
- package/Charting/Visuals/RenderableSeries/FastErrorBarsRenderableSeries.d.ts +188 -0
- package/Charting/Visuals/RenderableSeries/FastErrorBarsRenderableSeries.js +357 -0
- package/Charting/Visuals/RenderableSeries/FastImpulseRenderableSeries.js +3 -10
- package/Charting/Visuals/RenderableSeries/HitTest/ErrorSeriesHitTestProvider.d.ts +20 -0
- package/Charting/Visuals/RenderableSeries/HitTest/ErrorSeriesHitTestProvider.js +120 -0
- package/Charting/Visuals/RenderableSeries/HitTest/hitTestHelpers.d.ts +6 -0
- package/Charting/Visuals/RenderableSeries/HitTest/hitTestHelpers.js +36 -0
- package/Charting/Visuals/RenderableSeries/IBaseRenderableSeriesOptions.d.ts +8 -0
- package/Charting/Visuals/RenderableSeries/IRenderableSeries.d.ts +6 -0
- package/Charting/Visuals/RenderableSeries/SeriesVisibleChangedArgs.d.ts +6 -0
- package/Charting/Visuals/RenderableSeries/SeriesVisibleChangedArgs.js +11 -0
- package/Charting/Visuals/RenderableSeries/StackedColumnCollection.js +1 -2
- package/Charting/Visuals/RenderableSeries/StackedColumnRenderableSeries.d.ts +22 -0
- package/Charting/Visuals/RenderableSeries/StackedColumnRenderableSeries.js +38 -1
- package/Charting/Visuals/RenderableSeries/StackedMountainCollection.d.ts +2 -2
- package/Charting/Visuals/RenderableSeries/StackedMountainCollection.js +26 -45
- package/Charting/Visuals/RenderableSeries/StackedMountainRenderableSeries.d.ts +77 -18
- package/Charting/Visuals/RenderableSeries/StackedMountainRenderableSeries.js +139 -42
- package/Charting/Visuals/RenderableSeries/UniformHeatmapRenderableSeries.d.ts +13 -0
- package/Charting/Visuals/RenderableSeries/UniformHeatmapRenderableSeries.js +23 -3
- package/Charting/Visuals/RenderableSeries/XyScatterRenderableSeries.d.ts +5 -0
- package/Charting/Visuals/RenderableSeries/XyScatterRenderableSeries.js +21 -1
- package/Charting/Visuals/RenderableSeries/constants.d.ts +8 -0
- package/Charting/Visuals/RenderableSeries/constants.js +8 -0
- package/Charting/Visuals/SciChartPieSurface/IPieSurfaceOptions.d.ts +25 -2
- package/Charting/Visuals/SciChartPieSurface/PieSegment/IPieSegment.d.ts +9 -1
- package/Charting/Visuals/SciChartPieSurface/PieSegment/PieSegment.d.ts +128 -2
- package/Charting/Visuals/SciChartPieSurface/PieSegment/PieSegment.js +202 -21
- package/Charting/Visuals/SciChartPieSurface/PieSegment/constants.d.ts +6 -1
- package/Charting/Visuals/SciChartPieSurface/PieSegment/constants.js +5 -0
- package/Charting/Visuals/SciChartPieSurface/SciChartPieSurface.d.ts +77 -3
- package/Charting/Visuals/SciChartPieSurface/SciChartPieSurface.js +373 -81
- package/Charting/Visuals/SciChartPieSurface/constants.d.ts +7 -1
- package/Charting/Visuals/SciChartPieSurface/constants.js +6 -0
- package/Charting/Visuals/SciChartSurface.d.ts +13 -2
- package/Charting/Visuals/SciChartSurface.js +39 -3
- package/Charting/Visuals/createMaster.js +17 -13
- package/Charting/Visuals/createSingle.js +5 -3
- package/Charting/Visuals/licenseManager2D.d.ts +6 -0
- package/Charting/Visuals/licenseManager2D.js +83 -8
- package/Charting/Visuals/licenseManager2dState.d.ts +11 -0
- package/Charting/Visuals/licenseManager2dState.js +37 -1
- package/Charting/Visuals/loader.js +4 -1
- package/Charting/Visuals/sciChartInitCommon.d.ts +2 -2
- package/Charting/Visuals/sciChartInitCommon.js +13 -9
- package/Charting3D/Visuals/Primitives/ScatterPointsSceneEntity.js +6 -2
- package/Charting3D/Visuals/SciChart3DRenderer.js +1 -1
- package/Charting3D/Visuals/createMaster3d.js +20 -14
- package/Charting3D/Visuals/createSingle3d.js +3 -4
- package/Charting3D/Visuals/licenseManager3D.js +3 -1
- package/Core/BuildStamp.d.ts +1 -1
- package/Core/BuildStamp.js +2 -2
- package/Core/Telemetry.d.ts +7 -0
- package/Core/Telemetry.js +106 -0
- package/Core/storage/localStorageApi.d.ts +4 -0
- package/Core/storage/localStorageApi.js +12 -0
- package/_wasm/scichart.browser.js +1 -1
- package/_wasm/scichart2d.js +95 -95
- package/_wasm/scichart2d.wasm +0 -0
- package/_wasm/scichart3d.js +14 -14
- package/_wasm/scichart3d.wasm +0 -0
- package/package.json +1 -1
- package/types/AxisType.d.ts +5 -1
- package/types/AxisType.js +4 -0
- package/types/Color.d.ts +1 -0
- package/types/Color.js +1 -0
- package/types/DataFilterType.d.ts +1 -0
- package/types/DataFilterType.js +1 -0
- package/types/DataPointWidthMode.d.ts +13 -0
- package/types/DataPointWidthMode.js +17 -0
- package/types/ErrorDirection.d.ts +13 -0
- package/types/ErrorDirection.js +17 -0
- package/types/ErrorMode.d.ts +17 -0
- package/types/ErrorMode.js +21 -0
- package/types/LabelPlacement.d.ts +8 -0
- package/types/LabelPlacement.js +11 -1
- package/types/LabelProviderType.d.ts +5 -1
- package/types/LabelProviderType.js +4 -0
- package/types/SeriesType.d.ts +3 -1
- package/types/SeriesType.js +2 -0
- package/types/TSciChart.d.ts +8 -2
- package/types/TSciChart3D.d.ts +5 -2
- package/types/TSciChartSurfaceCanvases.d.ts +1 -0
- package/utils/date.d.ts +1 -0
- package/utils/date.js +15 -1
- package/utils/guid.d.ts +6 -0
- package/utils/guid.js +17 -1
|
@@ -30,6 +30,7 @@ import { IRenderableSeries } from "./IRenderableSeries";
|
|
|
30
30
|
import { RolloverModifierRenderableSeriesProps } from "./RolloverModifier/RolloverModifierRenderableSeriesProps";
|
|
31
31
|
import { SeriesHoveredArgs } from "./SeriesHoveredArgs";
|
|
32
32
|
import { SeriesSelectedArgs } from "./SeriesSelectedArgs";
|
|
33
|
+
import { SeriesVisibleChangedArgs } from "./SeriesVisibleChangedArgs";
|
|
33
34
|
import { ShaderEffect } from "./ShaderEffect";
|
|
34
35
|
/**
|
|
35
36
|
* @summary Defines the base class to a Render Series (or Chart Type) in SciChart's High Performance Real-time
|
|
@@ -47,23 +48,21 @@ export declare abstract class BaseRenderableSeries implements IRenderableSeries
|
|
|
47
48
|
/** @inheritDoc */
|
|
48
49
|
readonly id: string;
|
|
49
50
|
/** @inheritDoc */
|
|
50
|
-
readonly isStacked
|
|
51
|
+
readonly isStacked: boolean;
|
|
51
52
|
/** @inheritDoc */
|
|
52
53
|
readonly rolloverModifierProps: RolloverModifierRenderableSeriesProps;
|
|
53
54
|
/** @inheritDoc */
|
|
54
55
|
readonly rolloverModifierProps1: RolloverModifierRenderableSeriesProps;
|
|
55
56
|
/** @inheritDoc */
|
|
56
|
-
parentSurface: SciChartSurface;
|
|
57
|
-
/** @inheritDoc */
|
|
58
57
|
invalidateParentCallback: () => void;
|
|
59
58
|
/** @inheritDoc */
|
|
60
|
-
drawingProviders: ISeriesDrawingProvider[];
|
|
61
|
-
/** @inheritDoc */
|
|
62
59
|
hitTestProvider: IHitTestProvider;
|
|
63
60
|
/** @inheritDoc */
|
|
64
61
|
selected: EventHandler<SeriesSelectedArgs>;
|
|
65
62
|
/** @inheritDoc */
|
|
66
63
|
hovered: EventHandler<SeriesHoveredArgs>;
|
|
64
|
+
/** @inheritDoc */
|
|
65
|
+
isVisibleChanged: EventHandler<SeriesVisibleChangedArgs>;
|
|
67
66
|
protected webAssemblyContext: TSciChart;
|
|
68
67
|
protected dataSeriesProperty: IDataSeries;
|
|
69
68
|
protected animationFSM: SeriesAnimationFiniteStateMachine;
|
|
@@ -72,11 +71,14 @@ export declare abstract class BaseRenderableSeries implements IRenderableSeries
|
|
|
72
71
|
protected typeMap: Map<string, string>;
|
|
73
72
|
protected resamplerHelper: ExtremeResamplerHelper;
|
|
74
73
|
protected pointSeries: XyPointSeriesResampled;
|
|
74
|
+
protected currentRenderPassData: RenderPassData;
|
|
75
|
+
protected opacityProperty: number;
|
|
76
|
+
private parentSurfaceProperty;
|
|
77
|
+
private drawingProvidersProperty;
|
|
75
78
|
private xAxisIdProperty;
|
|
76
79
|
private yAxisIdProperty;
|
|
77
80
|
private strokeThicknessProperty;
|
|
78
81
|
private strokeProperty;
|
|
79
|
-
private opacityProperty;
|
|
80
82
|
private pointMarkerProperty;
|
|
81
83
|
private drawNaNAsProperty;
|
|
82
84
|
private isVisibleProperty;
|
|
@@ -84,7 +86,6 @@ export declare abstract class BaseRenderableSeries implements IRenderableSeries
|
|
|
84
86
|
private isDigitalLineProperty;
|
|
85
87
|
private isSelectedProperty;
|
|
86
88
|
private isHoveredProperty;
|
|
87
|
-
private currentRenderPassData;
|
|
88
89
|
private resamplingModeProperty;
|
|
89
90
|
private resamplingPrecisionProperty;
|
|
90
91
|
/**
|
|
@@ -97,6 +98,14 @@ export declare abstract class BaseRenderableSeries implements IRenderableSeries
|
|
|
97
98
|
/** @inheritDoc */
|
|
98
99
|
applyTheme(themeProvider: IThemeProvider): void;
|
|
99
100
|
/** @inheritDoc */
|
|
101
|
+
get parentSurface(): SciChartSurface;
|
|
102
|
+
/** @inheritDoc */
|
|
103
|
+
set parentSurface(value: SciChartSurface);
|
|
104
|
+
/** @inheritDoc */
|
|
105
|
+
get drawingProviders(): ISeriesDrawingProvider[];
|
|
106
|
+
/** @inheritDoc */
|
|
107
|
+
set drawingProviders(value: ISeriesDrawingProvider[]);
|
|
108
|
+
/** @inheritDoc */
|
|
100
109
|
get isSelected(): boolean;
|
|
101
110
|
/** @inheritDoc */
|
|
102
111
|
set isSelected(isSelected: boolean);
|
|
@@ -296,4 +305,11 @@ export declare abstract class BaseRenderableSeries implements IRenderableSeries
|
|
|
296
305
|
private effectPropertyChanged;
|
|
297
306
|
private get canDraw();
|
|
298
307
|
}
|
|
299
|
-
|
|
308
|
+
/** @ignore */
|
|
309
|
+
export declare const getDataPointWidth: (xValues: SCRTDoubleVector, xCoordCalc: CoordinateCalculatorBase, seriesViewRectWidth: number, widthFraction: number, isCategoryAxis: boolean, wasmContext: TSciChart) => number;
|
|
310
|
+
/** @ignore */
|
|
311
|
+
export declare const getDelta: ({ pointSize, areaSize, range }: {
|
|
312
|
+
pointSize: number;
|
|
313
|
+
areaSize: number;
|
|
314
|
+
range: NumberRange;
|
|
315
|
+
}) => number;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getDataPointWidth = exports.BaseRenderableSeries = void 0;
|
|
3
|
+
exports.getDelta = exports.getDataPointWidth = exports.BaseRenderableSeries = void 0;
|
|
4
4
|
var classFactory_1 = require("../../../Builder/classFactory");
|
|
5
5
|
var AnimationFiniteStateMachine_1 = require("../../../Core/Animations/AnimationFiniteStateMachine");
|
|
6
6
|
var Deleter_1 = require("../../../Core/Deleter");
|
|
@@ -13,6 +13,7 @@ var SeriesType_1 = require("../../../types/SeriesType");
|
|
|
13
13
|
var guid_1 = require("../../../utils/guid");
|
|
14
14
|
var WebGlRenderContext2D_1 = require("../../Drawing/WebGlRenderContext2D");
|
|
15
15
|
var HeatmapSeriesInfo_1 = require("../../Model/ChartData/HeatmapSeriesInfo");
|
|
16
|
+
var HlcSeriesInfo_1 = require("../../Model/ChartData/HlcSeriesInfo");
|
|
16
17
|
var OhlcSeriesInfo_1 = require("../../Model/ChartData/OhlcSeriesInfo");
|
|
17
18
|
var XySeriesInfo_1 = require("../../Model/ChartData/XySeriesInfo");
|
|
18
19
|
var XyySeriesInfo_1 = require("../../Model/ChartData/XyySeriesInfo");
|
|
@@ -25,11 +26,13 @@ var ResamplingMode_1 = require("../../Numerics/Resamplers/ResamplingMode");
|
|
|
25
26
|
var AxisCore_1 = require("../Axis/AxisCore");
|
|
26
27
|
var SciChartDefaults_1 = require("../SciChartDefaults");
|
|
27
28
|
var SciChartSurfaceBase_1 = require("../SciChartSurfaceBase");
|
|
29
|
+
var DpiHelper_1 = require("../TextureManager/DpiHelper");
|
|
28
30
|
var animationHelpers_1 = require("./Animations/animationHelpers");
|
|
29
31
|
var constants_1 = require("./constants");
|
|
30
32
|
var RolloverModifierRenderableSeriesProps_1 = require("./RolloverModifier/RolloverModifierRenderableSeriesProps");
|
|
31
33
|
var SeriesHoveredArgs_1 = require("./SeriesHoveredArgs");
|
|
32
34
|
var SeriesSelectedArgs_1 = require("./SeriesSelectedArgs");
|
|
35
|
+
var SeriesVisibleChangedArgs_1 = require("./SeriesVisibleChangedArgs");
|
|
33
36
|
/**
|
|
34
37
|
* @summary Defines the base class to a Render Series (or Chart Type) in SciChart's High Performance Real-time
|
|
35
38
|
* {@link https://www.scichart.com/javascript-chart-features | JavaScript Charts}
|
|
@@ -50,31 +53,31 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
50
53
|
function BaseRenderableSeries(webAssemblyContext, options) {
|
|
51
54
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
|
|
52
55
|
/** @inheritDoc */
|
|
53
|
-
this.isStacked = false;
|
|
54
|
-
/** @inheritDoc */
|
|
55
56
|
this.rolloverModifierProps = new RolloverModifierRenderableSeriesProps_1.RolloverModifierRenderableSeriesProps(this);
|
|
56
57
|
/** @inheritDoc */
|
|
57
58
|
this.rolloverModifierProps1 = new RolloverModifierRenderableSeriesProps_1.RolloverModifierRenderableSeriesProps(this, true);
|
|
58
59
|
/** @inheritDoc */
|
|
59
|
-
this.drawingProviders = [];
|
|
60
|
-
/** @inheritDoc */
|
|
61
60
|
this.selected = new EventHandler_1.EventHandler();
|
|
62
61
|
/** @inheritDoc */
|
|
63
62
|
this.hovered = new EventHandler_1.EventHandler();
|
|
63
|
+
/** @inheritDoc */
|
|
64
|
+
this.isVisibleChanged = new EventHandler_1.EventHandler();
|
|
64
65
|
this.animationQueue = [];
|
|
65
66
|
this.paletteProviderProperty = IPaletteProvider_1.DefaultPaletteProvider.createEmpty();
|
|
66
|
-
// used to track if registered types were used for function
|
|
67
|
+
// used to track if registered types were used for function properties, so they can be serialized
|
|
67
68
|
this.typeMap = new Map();
|
|
69
|
+
this.opacityProperty = 1;
|
|
70
|
+
this.drawingProvidersProperty = [];
|
|
68
71
|
this.xAxisIdProperty = AxisCore_1.AxisCore.DEFAULT_AXIS_ID;
|
|
69
72
|
this.yAxisIdProperty = AxisCore_1.AxisCore.DEFAULT_AXIS_ID;
|
|
70
73
|
this.strokeThicknessProperty = 2;
|
|
71
74
|
this.strokeProperty = SciChartSurfaceBase_1.SciChartSurfaceBase.DEFAULT_THEME.lineSeriesColor;
|
|
72
|
-
this.opacityProperty = 1;
|
|
73
75
|
this.drawNaNAsProperty = WebGlRenderContext2D_1.ELineDrawMode.DiscontinuousLine;
|
|
74
76
|
this.isVisibleProperty = true;
|
|
75
77
|
this.isDigitalLineProperty = false;
|
|
76
78
|
this.resamplingModeProperty = ResamplingMode_1.EResamplingMode.Auto;
|
|
77
79
|
this.resamplingPrecisionProperty = 0;
|
|
80
|
+
this.isStacked = false;
|
|
78
81
|
this.webAssemblyContext = webAssemblyContext;
|
|
79
82
|
this.id = (_a = options === null || options === void 0 ? void 0 : options.id) !== null && _a !== void 0 ? _a : (0, guid_1.generateGuid)();
|
|
80
83
|
// It is very important to add bind(this) first line in constructor,
|
|
@@ -113,7 +116,7 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
113
116
|
options.effect = (0, classFactory_1.createType)(BaseType_1.EBaseType.ShaderEffect, options.effect.type, webAssemblyContext, options.effect.options);
|
|
114
117
|
}
|
|
115
118
|
}
|
|
116
|
-
this.
|
|
119
|
+
this.effectProperty = options === null || options === void 0 ? void 0 : options.effect;
|
|
117
120
|
if (options === null || options === void 0 ? void 0 : options.paletteProvider) {
|
|
118
121
|
if (!("onAttached" in options.paletteProvider)) {
|
|
119
122
|
if (options.paletteProvider.type === PaletteProviderType_1.EPaletteProviderType.Custom) {
|
|
@@ -130,6 +133,21 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
130
133
|
this.hitTestProvider = this.newHitTestProvider();
|
|
131
134
|
this.isSelected = (_q = options === null || options === void 0 ? void 0 : options.isSelected) !== null && _q !== void 0 ? _q : false;
|
|
132
135
|
this.isHovered = (_r = options === null || options === void 0 ? void 0 : options.isHovered) !== null && _r !== void 0 ? _r : false;
|
|
136
|
+
if (options === null || options === void 0 ? void 0 : options.onIsVisibleChanged) {
|
|
137
|
+
if (typeof options.onIsVisibleChanged === "string") {
|
|
138
|
+
this.typeMap.set("onIsVisibleChanged", options.onIsVisibleChanged);
|
|
139
|
+
var visibleChanged_1 = (0, classFactory_1.getFunction)(BaseType_1.EBaseType.OptionFunction, options.onIsVisibleChanged);
|
|
140
|
+
this.isVisibleChanged.subscribe(function (args) {
|
|
141
|
+
return visibleChanged_1(args.sourceSeries, args.isVisible);
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
else {
|
|
145
|
+
var onIsVisibleChangedCallback_1 = options === null || options === void 0 ? void 0 : options.onIsVisibleChanged;
|
|
146
|
+
this.isVisibleChanged.subscribe(function (args) {
|
|
147
|
+
return onIsVisibleChangedCallback_1(args.sourceSeries, args.isVisible);
|
|
148
|
+
});
|
|
149
|
+
}
|
|
150
|
+
}
|
|
133
151
|
if (options === null || options === void 0 ? void 0 : options.onSelectedChanged) {
|
|
134
152
|
if (typeof options.onSelectedChanged === "string") {
|
|
135
153
|
this.typeMap.set("onSelectedChanged", options.onSelectedChanged);
|
|
@@ -182,6 +200,32 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
182
200
|
this.rolloverModifierProps.markerColor = themeProvider.textAnnotationBackground;
|
|
183
201
|
}
|
|
184
202
|
};
|
|
203
|
+
Object.defineProperty(BaseRenderableSeries.prototype, "parentSurface", {
|
|
204
|
+
/** @inheritDoc */
|
|
205
|
+
get: function () {
|
|
206
|
+
return this.parentSurfaceProperty;
|
|
207
|
+
},
|
|
208
|
+
/** @inheritDoc */
|
|
209
|
+
set: function (value) {
|
|
210
|
+
this.parentSurfaceProperty = value;
|
|
211
|
+
this.notifyPropertyChanged(constants_1.PROPERTY.PARENT_SURFACE);
|
|
212
|
+
},
|
|
213
|
+
enumerable: false,
|
|
214
|
+
configurable: true
|
|
215
|
+
});
|
|
216
|
+
Object.defineProperty(BaseRenderableSeries.prototype, "drawingProviders", {
|
|
217
|
+
/** @inheritDoc */
|
|
218
|
+
get: function () {
|
|
219
|
+
return this.drawingProvidersProperty;
|
|
220
|
+
},
|
|
221
|
+
/** @inheritDoc */
|
|
222
|
+
set: function (value) {
|
|
223
|
+
this.drawingProvidersProperty = value;
|
|
224
|
+
this.notifyPropertyChanged(constants_1.PROPERTY.DRAWING_PROVIDERS);
|
|
225
|
+
},
|
|
226
|
+
enumerable: false,
|
|
227
|
+
configurable: true
|
|
228
|
+
});
|
|
185
229
|
Object.defineProperty(BaseRenderableSeries.prototype, "isSelected", {
|
|
186
230
|
/** @inheritDoc */
|
|
187
231
|
get: function () {
|
|
@@ -248,8 +292,12 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
248
292
|
},
|
|
249
293
|
/** @inheritDoc */
|
|
250
294
|
set: function (isVisible) {
|
|
251
|
-
|
|
252
|
-
this.
|
|
295
|
+
var _a;
|
|
296
|
+
if (this.valueChanged(this.isVisibleProperty, isVisible)) {
|
|
297
|
+
this.isVisibleProperty = isVisible;
|
|
298
|
+
(_a = this.isVisibleChanged) === null || _a === void 0 ? void 0 : _a.raiseEvent(new SeriesVisibleChangedArgs_1.SeriesVisibleChangedArgs(this, isVisible));
|
|
299
|
+
this.notifyPropertyChanged(constants_1.PROPERTY.IS_VISIBLE);
|
|
300
|
+
}
|
|
253
301
|
},
|
|
254
302
|
enumerable: false,
|
|
255
303
|
configurable: true
|
|
@@ -376,10 +424,16 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
376
424
|
},
|
|
377
425
|
/** @inheritDoc */
|
|
378
426
|
set: function (dataSeries) {
|
|
379
|
-
var _a, _b;
|
|
380
|
-
(
|
|
427
|
+
var _a, _b, _c;
|
|
428
|
+
if (this.dataSeriesProperty) {
|
|
429
|
+
var xAxis = (_a = this.parentSurface) === null || _a === void 0 ? void 0 : _a.getXAxisById(this.xAxisId);
|
|
430
|
+
if (xAxis && xAxis.isCategoryAxis) {
|
|
431
|
+
xAxis.clearCoordCalcCache();
|
|
432
|
+
}
|
|
433
|
+
}
|
|
434
|
+
(_b = this.dataSeriesProperty) === null || _b === void 0 ? void 0 : _b.dataChanged.unsubscribe(this.dataSeriesDataChanged);
|
|
381
435
|
this.dataSeriesProperty = dataSeries;
|
|
382
|
-
(
|
|
436
|
+
(_c = this.dataSeriesProperty) === null || _c === void 0 ? void 0 : _c.dataChanged.subscribe(this.dataSeriesDataChanged);
|
|
383
437
|
this.notifyPropertyChanged(constants_1.PROPERTY.DATA_SERIES);
|
|
384
438
|
},
|
|
385
439
|
enumerable: false,
|
|
@@ -500,9 +554,9 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
500
554
|
*/
|
|
501
555
|
BaseRenderableSeries.prototype.getDataPointWidth = function (xCoordCalc, widthFraction) {
|
|
502
556
|
var xValues = this.dataSeries.getNativeXValues();
|
|
503
|
-
var seriesViewRectWidth =
|
|
504
|
-
var isCategoryAxis =
|
|
505
|
-
return (0, exports.getDataPointWidth)(xValues, xCoordCalc, seriesViewRectWidth, widthFraction, isCategoryAxis);
|
|
557
|
+
var seriesViewRectWidth = xCoordCalc.viewportDimension;
|
|
558
|
+
var isCategoryAxis = xCoordCalc.isCategoryCoordinateCalculator;
|
|
559
|
+
return (0, exports.getDataPointWidth)(xValues, xCoordCalc, seriesViewRectWidth, widthFraction, isCategoryAxis, this.webAssemblyContext);
|
|
506
560
|
};
|
|
507
561
|
/** @inheritDoc */
|
|
508
562
|
BaseRenderableSeries.prototype.onDetach = function () {
|
|
@@ -587,6 +641,8 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
587
641
|
return new XyySeriesInfo_1.XyySeriesInfo(this, hitTestInfo);
|
|
588
642
|
case IDataSeries_1.EDataSeriesType.HeatmapUniform:
|
|
589
643
|
return new HeatmapSeriesInfo_1.HeatmapSeriesInfo(this, hitTestInfo);
|
|
644
|
+
case IDataSeries_1.EDataSeriesType.Hlc:
|
|
645
|
+
return new HlcSeriesInfo_1.HlcSeriesInfo(this, hitTestInfo);
|
|
590
646
|
default:
|
|
591
647
|
return new XySeriesInfo_1.XySeriesInfo(this, hitTestInfo);
|
|
592
648
|
}
|
|
@@ -602,7 +658,7 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
602
658
|
};
|
|
603
659
|
/** @inheritDoc */
|
|
604
660
|
BaseRenderableSeries.prototype.toJSON = function (excludeData) {
|
|
605
|
-
var _a, _b, _c, _d, _e, _f, _g;
|
|
661
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
606
662
|
if (excludeData === void 0) { excludeData = false; }
|
|
607
663
|
var paletteProvider;
|
|
608
664
|
if (this.paletteProvider) {
|
|
@@ -634,27 +690,24 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
634
690
|
// onSelectedChanged: this.onSelectedChanged
|
|
635
691
|
};
|
|
636
692
|
if (((_c = this.dataSeries) === null || _c === void 0 ? void 0 : _c.type) === IDataSeries_1.EDataSeriesType.Xy) {
|
|
637
|
-
// @ts-ignore
|
|
638
693
|
return { type: this.type, options: options, xyData: this.dataSeries.toJSON(excludeData) };
|
|
639
694
|
}
|
|
640
695
|
else if (((_d = this.dataSeries) === null || _d === void 0 ? void 0 : _d.type) === IDataSeries_1.EDataSeriesType.Xyy) {
|
|
641
|
-
// @ts-ignore
|
|
642
696
|
return { type: this.type, options: options, xyyData: this.dataSeries.toJSON(excludeData) };
|
|
643
697
|
}
|
|
644
698
|
else if (((_e = this.dataSeries) === null || _e === void 0 ? void 0 : _e.type) === IDataSeries_1.EDataSeriesType.Xyz) {
|
|
645
|
-
// @ts-ignore
|
|
646
699
|
return { type: this.type, options: options, xyzData: this.dataSeries.toJSON(excludeData) };
|
|
647
700
|
}
|
|
648
701
|
else if (((_f = this.dataSeries) === null || _f === void 0 ? void 0 : _f.type) === IDataSeries_1.EDataSeriesType.Ohlc) {
|
|
649
|
-
// @ts-ignore
|
|
650
702
|
return { type: this.type, options: options, ohlcData: this.dataSeries.toJSON(excludeData) };
|
|
651
703
|
}
|
|
652
|
-
else if (((_g = this.dataSeries) === null || _g === void 0 ? void 0 : _g.type) === IDataSeries_1.EDataSeriesType.
|
|
653
|
-
|
|
704
|
+
else if (((_g = this.dataSeries) === null || _g === void 0 ? void 0 : _g.type) === IDataSeries_1.EDataSeriesType.Hlc) {
|
|
705
|
+
return { type: this.type, options: options, hlcData: this.dataSeries.toJSON(excludeData) };
|
|
706
|
+
}
|
|
707
|
+
else if (((_h = this.dataSeries) === null || _h === void 0 ? void 0 : _h.type) === IDataSeries_1.EDataSeriesType.HeatmapUniform) {
|
|
654
708
|
return { type: this.type, options: options, heatmapData: this.dataSeries.toJSON(excludeData) };
|
|
655
709
|
}
|
|
656
710
|
else {
|
|
657
|
-
// @ts-ignore
|
|
658
711
|
return { type: this.type, options: options };
|
|
659
712
|
}
|
|
660
713
|
};
|
|
@@ -729,9 +782,7 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
729
782
|
this.pointSeries.xRange = rp.xVisibleRange;
|
|
730
783
|
}
|
|
731
784
|
this.resamplerHelper.resampleIntoPointSeries(this.webAssemblyContext, rp, this.dataSeries.getNativeXValues(), this.dataSeries.getNativeYValues(), this.pointSeries.intIndexes, this.pointSeries.xValues, this.pointSeries.yValues, false);
|
|
732
|
-
|
|
733
|
-
this.pointSeries.updateIndexes();
|
|
734
|
-
}
|
|
785
|
+
this.pointSeries.updateIndexes();
|
|
735
786
|
this.pointSeries.clearIntIndexes();
|
|
736
787
|
// this.pointSeries.debugOutputForUnitTests();
|
|
737
788
|
return this.pointSeries;
|
|
@@ -756,11 +807,13 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
756
807
|
var seriesTypeSupportsResampling = ![
|
|
757
808
|
SeriesType_1.ESeriesType.UniformContoursSeries,
|
|
758
809
|
SeriesType_1.ESeriesType.UniformHeatmapSeries,
|
|
759
|
-
SeriesType_1.ESeriesType.ScatterSeries
|
|
810
|
+
SeriesType_1.ESeriesType.ScatterSeries,
|
|
811
|
+
SeriesType_1.ESeriesType.ErrorBarsSeries
|
|
760
812
|
].includes(this.type);
|
|
761
813
|
return (seriesTypeSupportsResampling &&
|
|
762
814
|
SciChartDefaults_1.SciChartDefaults.enableResampling &&
|
|
763
815
|
this.enableDrawingOptimisations &&
|
|
816
|
+
!this.isStacked &&
|
|
764
817
|
this.dataSeries &&
|
|
765
818
|
this.dataSeries.count() > 0 &&
|
|
766
819
|
this.dataSeries.dataDistributionCalculator.isSortedAscending);
|
|
@@ -871,7 +924,8 @@ var BaseRenderableSeries = /** @class */ (function () {
|
|
|
871
924
|
return BaseRenderableSeries;
|
|
872
925
|
}());
|
|
873
926
|
exports.BaseRenderableSeries = BaseRenderableSeries;
|
|
874
|
-
|
|
927
|
+
/** @ignore */
|
|
928
|
+
var getDataPointWidth = function (xValues, xCoordCalc, seriesViewRectWidth, widthFraction, isCategoryAxis, wasmContext) {
|
|
875
929
|
if (widthFraction < 0 || widthFraction > 1) {
|
|
876
930
|
throw new Error("WidthFraction should be between 0.0 and 1.0 inclusive");
|
|
877
931
|
}
|
|
@@ -881,12 +935,28 @@ var getDataPointWidth = function (xValues, xCoordCalc, seriesViewRectWidth, widt
|
|
|
881
935
|
var barsAmount = count;
|
|
882
936
|
// TODO: logarithmic axis
|
|
883
937
|
if (barsAmount > 1) {
|
|
884
|
-
var max =
|
|
885
|
-
var min =
|
|
938
|
+
var max = Number.MIN_VALUE;
|
|
939
|
+
var min = Number.MAX_VALUE;
|
|
886
940
|
if (isCategoryAxis) {
|
|
887
941
|
max = xCoordCalc.getCoordinate(count - 1);
|
|
888
942
|
min = xCoordCalc.getCoordinate(0);
|
|
889
943
|
}
|
|
944
|
+
else {
|
|
945
|
+
var minMax = void 0;
|
|
946
|
+
try {
|
|
947
|
+
minMax = wasmContext.NumberUtil.MinMax(xValues);
|
|
948
|
+
// if (!isRealNumber(minMax.minD) || !isRealNumber(minMax.maxD)) {
|
|
949
|
+
// return new NumberRange(0, 0);
|
|
950
|
+
// }
|
|
951
|
+
min = minMax.minD;
|
|
952
|
+
max = minMax.maxD;
|
|
953
|
+
}
|
|
954
|
+
finally {
|
|
955
|
+
(0, Deleter_1.deleteSafe)(minMax);
|
|
956
|
+
}
|
|
957
|
+
max = xCoordCalc.getCoordinate(max);
|
|
958
|
+
min = xCoordCalc.getCoordinate(min);
|
|
959
|
+
}
|
|
890
960
|
dataPointWidth = Math.abs(max - min) / (barsAmount - 1);
|
|
891
961
|
}
|
|
892
962
|
else if (barsAmount === 1) {
|
|
@@ -899,3 +969,11 @@ var getDataPointWidth = function (xValues, xCoordCalc, seriesViewRectWidth, widt
|
|
|
899
969
|
return candleWidth;
|
|
900
970
|
};
|
|
901
971
|
exports.getDataPointWidth = getDataPointWidth;
|
|
972
|
+
/** @ignore */
|
|
973
|
+
var getDelta = function (_a) {
|
|
974
|
+
var pointSize = _a.pointSize, areaSize = _a.areaSize, range = _a.range;
|
|
975
|
+
var pointScaled = pointSize * DpiHelper_1.DpiHelper.PIXEL_RATIO;
|
|
976
|
+
var k = areaSize / (areaSize - pointScaled);
|
|
977
|
+
return (Math.abs(range.max - range.min) * (k - 1)) / 2;
|
|
978
|
+
};
|
|
979
|
+
exports.getDelta = getDelta;
|
|
@@ -29,6 +29,7 @@ import { RolloverModifierRenderableSeriesProps } from "./RolloverModifier/Rollov
|
|
|
29
29
|
import { SeriesHoveredArgs } from "./SeriesHoveredArgs";
|
|
30
30
|
import { SeriesSelectedArgs } from "./SeriesSelectedArgs";
|
|
31
31
|
import { ShaderEffect } from "./ShaderEffect";
|
|
32
|
+
import { SeriesVisibleChangedArgs } from "./SeriesVisibleChangedArgs";
|
|
32
33
|
/**
|
|
33
34
|
* Options to pass to the {@link BaseStackedCollection} constructor
|
|
34
35
|
*/
|
|
@@ -99,6 +100,8 @@ export declare abstract class BaseStackedCollection<T extends BaseStackedRendera
|
|
|
99
100
|
*/
|
|
100
101
|
protected constructor(webAssemblyContext: TSciChart, options?: IBaseStackedCollectionOptions);
|
|
101
102
|
/** @inheritDoc */
|
|
103
|
+
get isVisibleChanged(): EventHandler<SeriesVisibleChangedArgs>;
|
|
104
|
+
/** @inheritDoc */
|
|
102
105
|
get selected(): EventHandler<SeriesSelectedArgs>;
|
|
103
106
|
/** @inheritDoc */
|
|
104
107
|
get hovered(): EventHandler<SeriesHoveredArgs>;
|
|
@@ -72,6 +72,14 @@ var BaseStackedCollection = /** @class */ (function (_super) {
|
|
|
72
72
|
_this.accumulatedFinalAnimationValues0 = new _this.webAssemblyContext.SCRTDoubleVector();
|
|
73
73
|
return _this;
|
|
74
74
|
}
|
|
75
|
+
Object.defineProperty(BaseStackedCollection.prototype, "isVisibleChanged", {
|
|
76
|
+
/** @inheritDoc */
|
|
77
|
+
get: function () {
|
|
78
|
+
throw new Error("getting visibleChanged event is not supported for BaseStackedCollection");
|
|
79
|
+
},
|
|
80
|
+
enumerable: false,
|
|
81
|
+
configurable: true
|
|
82
|
+
});
|
|
75
83
|
Object.defineProperty(BaseStackedCollection.prototype, "selected", {
|
|
76
84
|
/** @inheritDoc */
|
|
77
85
|
get: function () {
|