scichart 3.1.348 → 3.2.434

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.
Files changed (358) hide show
  1. package/Builder/buildSurface.d.ts +2 -2
  2. package/Builder/chartBuilder.d.ts +4 -4
  3. package/Charting/ChartModifiers/ChartModifierBase.d.ts +19 -5
  4. package/Charting/ChartModifiers/ChartModifierBase.js +64 -7
  5. package/Charting/ChartModifiers/CursorModifier.d.ts +9 -9
  6. package/Charting/ChartModifiers/CursorModifier.js +13 -1
  7. package/Charting/ChartModifiers/DataPointSelectionModifier.d.ts +1 -0
  8. package/Charting/ChartModifiers/DataPointSelectionModifier.js +6 -1
  9. package/Charting/ChartModifiers/LegendModifier.d.ts +10 -25
  10. package/Charting/ChartModifiers/LegendModifier.js +10 -20
  11. package/Charting/ChartModifiers/MouseWheelZoomModifier.js +20 -11
  12. package/Charting/ChartModifiers/OverviewRangeSelectionModifier.d.ts +5 -5
  13. package/Charting/ChartModifiers/PinchZoomModifier.d.ts +38 -8
  14. package/Charting/ChartModifiers/PinchZoomModifier.js +103 -40
  15. package/Charting/ChartModifiers/RolloverModifier.js +10 -3
  16. package/Charting/ChartModifiers/RubberBandXyZoomModifier.d.ts +4 -7
  17. package/Charting/ChartModifiers/RubberBandXyZoomModifier.js +6 -8
  18. package/Charting/ChartModifiers/SeriesSelectionModifier.js +39 -29
  19. package/Charting/ChartModifiers/XAxisDragModifier.d.ts +1 -1
  20. package/Charting/ChartModifiers/XAxisDragModifier.js +3 -3
  21. package/Charting/ChartModifiers/YAxisDragModifier.d.ts +2 -4
  22. package/Charting/ChartModifiers/YAxisDragModifier.js +7 -8
  23. package/Charting/ChartModifiers/ZoomPanModifier.d.ts +13 -38
  24. package/Charting/ChartModifiers/ZoomPanModifier.js +54 -99
  25. package/Charting/Drawing/BaseCache.d.ts +2 -1
  26. package/Charting/Drawing/BaseCache.js +45 -7
  27. package/Charting/Drawing/RenderSurface.d.ts +1 -0
  28. package/Charting/Drawing/RenderSurface.js +5 -1
  29. package/Charting/Drawing/SolidBrushCache.d.ts +2 -1
  30. package/Charting/Drawing/SolidBrushCache.js +23 -3
  31. package/Charting/Drawing/WebGlBrush.d.ts +2 -1
  32. package/Charting/Drawing/WebGlBrush.js +22 -3
  33. package/Charting/Drawing/WebGlPen.d.ts +2 -1
  34. package/Charting/Drawing/WebGlPen.js +23 -4
  35. package/Charting/Drawing/WebGlRenderContext2D.d.ts +4 -3
  36. package/Charting/Drawing/WebGlRenderContext2D.js +26 -7
  37. package/Charting/Model/BaseDataSeries.d.ts +67 -2
  38. package/Charting/Model/BaseDataSeries.js +193 -42
  39. package/Charting/Model/BaseHeatmapDataSeries.js +1 -1
  40. package/Charting/Model/ChartData/SeriesInfo.d.ts +16 -0
  41. package/Charting/Model/ChartData/SeriesInfo.js +7 -0
  42. package/Charting/Model/ChartData/XyzSeriesInfo.d.ts +8 -0
  43. package/Charting/Model/ChartData/XyzSeriesInfo.js +36 -0
  44. package/Charting/Model/DoubleVectorProvider.d.ts +19 -0
  45. package/Charting/Model/DoubleVectorProvider.js +95 -0
  46. package/Charting/Model/Filters/HlcFilterBase.d.ts +6 -2
  47. package/Charting/Model/Filters/HlcFilterBase.js +17 -1
  48. package/Charting/Model/Filters/IFilterBase.d.ts +24 -0
  49. package/Charting/Model/Filters/IFilterBase.js +2 -0
  50. package/Charting/Model/Filters/OhlcFilterBase.d.ts +6 -2
  51. package/Charting/Model/Filters/OhlcFilterBase.js +17 -1
  52. package/Charting/Model/Filters/XyFilterBase.d.ts +6 -5
  53. package/Charting/Model/Filters/XyFilterBase.js +17 -1
  54. package/Charting/Model/Filters/XyyFilterBase.d.ts +6 -2
  55. package/Charting/Model/Filters/XyyFilterBase.js +17 -1
  56. package/Charting/Model/Filters/XyzFilterBase.d.ts +6 -2
  57. package/Charting/Model/Filters/XyzFilterBase.js +17 -1
  58. package/Charting/Model/HlcDataSeries.d.ts +3 -0
  59. package/Charting/Model/HlcDataSeries.js +44 -15
  60. package/Charting/Model/IDataSeries.d.ts +23 -0
  61. package/Charting/Model/NonUniformHeatmapDataSeries.js +2 -0
  62. package/Charting/Model/OhlcDataSeries.d.ts +3 -0
  63. package/Charting/Model/OhlcDataSeries.js +56 -24
  64. package/Charting/Model/PointSeries/BasePointSeriesResampled.d.ts +4 -5
  65. package/Charting/Model/PointSeries/BasePointSeriesResampled.js +29 -21
  66. package/Charting/Model/PointSeries/BasePointSeriesWrapped.d.ts +2 -0
  67. package/Charting/Model/PointSeries/BasePointSeriesWrapped.js +2 -0
  68. package/Charting/Model/PointSeries/IPointSeries.d.ts +2 -1
  69. package/Charting/Model/PointSeries/OhlcPointSeriesResampled.js +1 -1
  70. package/Charting/Model/PointSeries/XyPointSeriesWrapped.d.ts +2 -1
  71. package/Charting/Model/PointSeries/XyPointSeriesWrapped.js +2 -2
  72. package/Charting/Model/PointSeries/XyyPointSeriesResampled.js +1 -1
  73. package/Charting/Model/UniformHeatmapDataSeries.d.ts +31 -11
  74. package/Charting/Model/UniformHeatmapDataSeries.js +72 -4
  75. package/Charting/Model/XyDataSeries.d.ts +0 -8
  76. package/Charting/Model/XyDataSeries.js +21 -5
  77. package/Charting/Model/XyTextDataSeries.d.ts +2 -0
  78. package/Charting/Model/XyTextDataSeries.js +35 -4
  79. package/Charting/Model/XyyDataSeries.d.ts +2 -0
  80. package/Charting/Model/XyyDataSeries.js +50 -26
  81. package/Charting/Model/XyzDataSeries.d.ts +3 -0
  82. package/Charting/Model/XyzDataSeries.js +36 -10
  83. package/Charting/Numerics/CoordinateCalculators/CategoryCoordinateCalculator.d.ts +3 -5
  84. package/Charting/Numerics/CoordinateCalculators/CategoryCoordinateCalculator.js +5 -7
  85. package/Charting/Numerics/CoordinateCalculators/CoordinateCalculatorBase.d.ts +2 -1
  86. package/Charting/Numerics/CoordinateCalculators/CoordinateCalculatorBase.js +29 -9
  87. package/Charting/Numerics/CoordinateCalculators/FlippedCategoryCoordinateCalculator.d.ts +3 -5
  88. package/Charting/Numerics/CoordinateCalculators/FlippedCategoryCoordinateCalculator.js +5 -7
  89. package/Charting/Numerics/Resamplers/ExtremeResamplerHelper.d.ts +14 -10
  90. package/Charting/Numerics/Resamplers/ExtremeResamplerHelper.js +105 -69
  91. package/Charting/Numerics/Resamplers/ResamplingParams.d.ts +4 -2
  92. package/Charting/Numerics/Resamplers/ResamplingParams.js +12 -7
  93. package/Charting/Numerics/TickCoordinateProviders/TickCoordinatesProvider.d.ts +5 -0
  94. package/Charting/Numerics/TickCoordinateProviders/TickCoordinatesProvider.js +7 -0
  95. package/Charting/Numerics/TickProviders/NumericTickProvider.js +3 -4
  96. package/Charting/Numerics/TickProviders/TickProvider.d.ts +5 -0
  97. package/Charting/Numerics/TickProviders/TickProvider.js +7 -0
  98. package/Charting/Services/SciChartRenderer.js +15 -5
  99. package/Charting/Services/TitleRenderer.d.ts +2 -1
  100. package/Charting/Services/TitleRenderer.js +35 -14
  101. package/Charting/Visuals/Annotations/AdornerLayer.d.ts +1 -1
  102. package/Charting/Visuals/Annotations/AnnotationBase.d.ts +6 -6
  103. package/Charting/Visuals/Annotations/AnnotationBase.js +81 -61
  104. package/Charting/Visuals/Annotations/CursorTooltipSvgAnnotation.js +4 -0
  105. package/Charting/Visuals/Annotations/IAnnotation.d.ts +9 -4
  106. package/Charting/Visuals/Annotations/IAnnotation.js +6 -0
  107. package/Charting/Visuals/Annotations/LineAnnotation.js +3 -1
  108. package/Charting/Visuals/Annotations/NativeTextAnnotation.js +4 -0
  109. package/Charting/Visuals/Annotations/RenderContextAnnotationBase.d.ts +5 -0
  110. package/Charting/Visuals/Annotations/RenderContextAnnotationBase.js +16 -0
  111. package/Charting/Visuals/Annotations/RolloverTooltipSvgAnnotation.js +6 -0
  112. package/Charting/Visuals/Annotations/constants.d.ts +1 -0
  113. package/Charting/Visuals/Annotations/constants.js +1 -0
  114. package/Charting/Visuals/Axis/AxisBase2D.d.ts +23 -8
  115. package/Charting/Visuals/Axis/AxisBase2D.js +46 -10
  116. package/Charting/Visuals/Axis/AxisCore.d.ts +6 -3
  117. package/Charting/Visuals/Axis/AxisCore.js +100 -54
  118. package/Charting/Visuals/Axis/AxisRenderer.d.ts +2 -1
  119. package/Charting/Visuals/Axis/AxisRenderer.js +40 -16
  120. package/Charting/Visuals/Axis/AxisTitleRenderer.d.ts +1 -0
  121. package/Charting/Visuals/Axis/AxisTitleRenderer.js +4 -0
  122. package/Charting/Visuals/Axis/CategoryAxisBase.js +4 -4
  123. package/Charting/Visuals/Axis/DeltaCalculator/DateTimeDeltaCalculator.js +14 -9
  124. package/Charting/Visuals/Axis/DeltaCalculator/DeltaCalculator.d.ts +5 -0
  125. package/Charting/Visuals/Axis/DeltaCalculator/DeltaCalculator.js +7 -0
  126. package/Charting/Visuals/Axis/LabelProvider/LabelCache.d.ts +2 -2
  127. package/Charting/Visuals/Axis/LabelProvider/LabelCache.js +8 -1
  128. package/Charting/Visuals/Axis/LabelProvider/LabelProvider.d.ts +7 -1
  129. package/Charting/Visuals/Axis/LabelProvider/LabelProvider.js +34 -8
  130. package/Charting/Visuals/Axis/LabelProvider/LabelProviderBase2D.d.ts +4 -2
  131. package/Charting/Visuals/Axis/LabelProvider/LabelProviderBase2D.js +8 -2
  132. package/Charting/Visuals/Axis/LabelProvider/PieLabelProvider.d.ts +1 -0
  133. package/Charting/Visuals/Axis/LabelProvider/PieLabelProvider.js +1 -0
  134. package/Charting/Visuals/HeatmapLegend.d.ts +3 -2
  135. package/Charting/Visuals/HeatmapLegend.js +33 -12
  136. package/Charting/Visuals/Helpers/NativeObject.d.ts +8 -5
  137. package/Charting/Visuals/Helpers/NativeObject.js +42 -21
  138. package/Charting/Visuals/Helpers/drawLabel.js +3 -1
  139. package/Charting/Visuals/I2DSurfaceOptions.d.ts +0 -15
  140. package/Charting/Visuals/Legend/ManualLegend.d.ts +56 -0
  141. package/Charting/Visuals/Legend/ManualLegend.js +138 -0
  142. package/Charting/Visuals/Legend/SciChartLegend.js +4 -3
  143. package/Charting/Visuals/Legend/SciChartLegendBase.d.ts +65 -4
  144. package/Charting/Visuals/Legend/SciChartLegendBase.js +111 -23
  145. package/Charting/Visuals/Legend/SciChartPieLegend.js +1 -1
  146. package/Charting/Visuals/PointMarkers/BasePointMarker.d.ts +13 -1
  147. package/Charting/Visuals/PointMarkers/BasePointMarker.js +77 -19
  148. package/Charting/Visuals/PointMarkers/Constants.d.ts +2 -1
  149. package/Charting/Visuals/PointMarkers/Constants.js +1 -0
  150. package/Charting/Visuals/PointMarkers/IPointMarker.d.ts +2 -0
  151. package/Charting/Visuals/RenderableSeries/Animations/SeriesAnimation.js +4 -1
  152. package/Charting/Visuals/RenderableSeries/Animations/animationHelpers.d.ts +1 -1
  153. package/Charting/Visuals/RenderableSeries/BaseBandRenderableSeries.js +8 -7
  154. package/Charting/Visuals/RenderableSeries/BaseHeatmapRenderableSeries.d.ts +1 -0
  155. package/Charting/Visuals/RenderableSeries/BaseHeatmapRenderableSeries.js +5 -0
  156. package/Charting/Visuals/RenderableSeries/BaseOhlcRenderableSeries.js +10 -9
  157. package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.d.ts +3 -2
  158. package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.js +101 -69
  159. package/Charting/Visuals/RenderableSeries/BaseStackedCollection.js +18 -4
  160. package/Charting/Visuals/RenderableSeries/BaseStackedRenderableSeries.js +12 -3
  161. package/Charting/Visuals/RenderableSeries/DataLabels/BaseDataLabelProvider.d.ts +2 -0
  162. package/Charting/Visuals/RenderableSeries/DataLabels/BaseDataLabelProvider.js +5 -0
  163. package/Charting/Visuals/RenderableSeries/DataLabels/DataLabelProvider.js +6 -0
  164. package/Charting/Visuals/RenderableSeries/DataLabels/DataLabelState.d.ts +1 -0
  165. package/Charting/Visuals/RenderableSeries/DataLabels/DataLabelState.js +18 -5
  166. package/Charting/Visuals/RenderableSeries/DataLabels/NonUniformHeatmapDataLabelProvider.js +0 -1
  167. package/Charting/Visuals/RenderableSeries/DataLabels/TextDataLabelProvider.js +8 -2
  168. package/Charting/Visuals/RenderableSeries/DrawingProviders/BandSeriesDrawingProvider.d.ts +1 -0
  169. package/Charting/Visuals/RenderableSeries/DrawingProviders/BandSeriesDrawingProvider.js +35 -16
  170. package/Charting/Visuals/RenderableSeries/DrawingProviders/BaseSeriesDrawingProvider.d.ts +5 -4
  171. package/Charting/Visuals/RenderableSeries/DrawingProviders/BaseSeriesDrawingProvider.js +70 -33
  172. package/Charting/Visuals/RenderableSeries/DrawingProviders/BubbleSeriesDrawingProvider.d.ts +1 -0
  173. package/Charting/Visuals/RenderableSeries/DrawingProviders/BubbleSeriesDrawingProvider.js +30 -9
  174. package/Charting/Visuals/RenderableSeries/DrawingProviders/ColumnSeriesDrawingProvider.d.ts +1 -0
  175. package/Charting/Visuals/RenderableSeries/DrawingProviders/ColumnSeriesDrawingProvider.js +37 -16
  176. package/Charting/Visuals/RenderableSeries/DrawingProviders/HeatmapHelpers.d.ts +47 -0
  177. package/Charting/Visuals/RenderableSeries/DrawingProviders/HeatmapHelpers.js +258 -0
  178. package/Charting/Visuals/RenderableSeries/DrawingProviders/LineSeriesDrawingProvider.js +26 -2
  179. package/Charting/Visuals/RenderableSeries/DrawingProviders/MountainSeriesDrawingProvider.d.ts +1 -0
  180. package/Charting/Visuals/RenderableSeries/DrawingProviders/MountainSeriesDrawingProvider.js +34 -15
  181. package/Charting/Visuals/RenderableSeries/DrawingProviders/NonUniformHeatmapDrawingProvider.js +5 -230
  182. package/Charting/Visuals/RenderableSeries/DrawingProviders/OhlcSeriesDrawingProvider.d.ts +1 -0
  183. package/Charting/Visuals/RenderableSeries/DrawingProviders/OhlcSeriesDrawingProvider.js +62 -37
  184. package/Charting/Visuals/RenderableSeries/DrawingProviders/PointMarkerDrawingProvider.js +30 -3
  185. package/Charting/Visuals/RenderableSeries/DrawingProviders/UniformHeatmapDrawingProvider.d.ts +1 -0
  186. package/Charting/Visuals/RenderableSeries/DrawingProviders/UniformHeatmapDrawingProvider.js +4 -1
  187. package/Charting/Visuals/RenderableSeries/FastBubbleRenderableSeries.d.ts +0 -2
  188. package/Charting/Visuals/RenderableSeries/FastBubbleRenderableSeries.js +0 -4
  189. package/Charting/Visuals/RenderableSeries/FastTextRenderableSeries.d.ts +3 -0
  190. package/Charting/Visuals/RenderableSeries/FastTextRenderableSeries.js +10 -0
  191. package/Charting/Visuals/RenderableSeries/HitTest/BubbleSeriesHitTestProvider.d.ts +4 -0
  192. package/Charting/Visuals/RenderableSeries/HitTest/BubbleSeriesHitTestProvider.js +7 -0
  193. package/Charting/Visuals/RenderableSeries/HitTest/HitTestInfo.d.ts +4 -0
  194. package/Charting/Visuals/RenderableSeries/HitTest/HitTestInfo.js +9 -0
  195. package/Charting/Visuals/RenderableSeries/HoveredChangedArgs.d.ts +6 -1
  196. package/Charting/Visuals/RenderableSeries/HoveredChangedArgs.js +2 -1
  197. package/Charting/Visuals/RenderableSeries/IRenderableSeries.d.ts +1 -1
  198. package/Charting/Visuals/RenderableSeries/SelectionChangedArgs.d.ts +6 -1
  199. package/Charting/Visuals/RenderableSeries/SelectionChangedArgs.js +2 -1
  200. package/Charting/Visuals/RenderableSeries/ShaderEffect.d.ts +3 -2
  201. package/Charting/Visuals/RenderableSeries/ShaderEffect.js +29 -9
  202. package/Charting/Visuals/RenderableSeries/SplineBandRenderableSeries.js +50 -1
  203. package/Charting/Visuals/RenderableSeries/SplineLineRenderableSeries.js +13 -1
  204. package/Charting/Visuals/RenderableSeries/SplineMountainRenderableSeries.js +13 -1
  205. package/Charting/Visuals/RenderableSeries/StackedColumnCollection.js +3 -0
  206. package/Charting/Visuals/RenderableSeries/StackedMountainCollection.d.ts +0 -2
  207. package/Charting/Visuals/RenderableSeries/StackedMountainCollection.js +4 -4
  208. package/Charting/Visuals/RenderableSeries/StackedMountainRenderableSeries.d.ts +1 -0
  209. package/Charting/Visuals/RenderableSeries/StackedMountainRenderableSeries.js +8 -0
  210. package/Charting/Visuals/RenderableSeries/XyScatterRenderableSeries.d.ts +1 -2
  211. package/Charting/Visuals/RenderableSeries/XyScatterRenderableSeries.js +8 -3
  212. package/Charting/Visuals/RubberBandSvgRect/RubberBandSvgRect.d.ts +7 -1
  213. package/Charting/Visuals/RubberBandSvgRect/RubberBandSvgRect.js +38 -12
  214. package/Charting/Visuals/SciChartDefaults.d.ts +10 -0
  215. package/Charting/Visuals/SciChartDefaults.js +10 -0
  216. package/Charting/Visuals/SciChartOverview.d.ts +2 -1
  217. package/Charting/Visuals/SciChartOverview.js +28 -8
  218. package/Charting/Visuals/SciChartPieSurface/SciChartPieSurface.d.ts +16 -3
  219. package/Charting/Visuals/SciChartPieSurface/SciChartPieSurface.js +125 -60
  220. package/Charting/Visuals/SciChartSurface.d.ts +4 -41
  221. package/Charting/Visuals/SciChartSurface.js +52 -66
  222. package/Charting/Visuals/SciChartSurfaceBase.d.ts +117 -13
  223. package/Charting/Visuals/SciChartSurfaceBase.js +177 -32
  224. package/Charting/Visuals/TextureManager/CanvasTexture.d.ts +2 -1
  225. package/Charting/Visuals/TextureManager/CanvasTexture.js +37 -17
  226. package/Charting/Visuals/TextureManager/TextureManager.d.ts +2 -1
  227. package/Charting/Visuals/TextureManager/TextureManager.js +27 -7
  228. package/Charting/Visuals/createMaster.d.ts +7 -2
  229. package/Charting/Visuals/createMaster.js +140 -45
  230. package/Charting/Visuals/createSingle.d.ts +0 -2
  231. package/Charting/Visuals/createSingle.js +46 -11
  232. package/Charting/Visuals/licenseManager2D.d.ts +7 -5
  233. package/Charting/Visuals/licenseManager2D.js +105 -53
  234. package/Charting/Visuals/loader.js +3 -1
  235. package/Charting/Visuals/sciChartInitCommon.d.ts +1 -1
  236. package/Charting/Visuals/sciChartInitCommon.js +5 -1
  237. package/Charting3D/CameraController.d.ts +1 -1
  238. package/Charting3D/CameraController.js +21 -7
  239. package/Charting3D/ChartModifiers/ChartModifierBase3D.d.ts +1 -0
  240. package/Charting3D/ChartModifiers/ChartModifierBase3D.js +4 -1
  241. package/Charting3D/ChartModifiers/OrbitModifier3D.d.ts +17 -5
  242. package/Charting3D/ChartModifiers/OrbitModifier3D.js +62 -26
  243. package/Charting3D/ChartModifiers/PinchZoomModifier3D.d.ts +81 -0
  244. package/Charting3D/ChartModifiers/PinchZoomModifier3D.js +164 -0
  245. package/Charting3D/ChartModifiers/ResetCamera3DModifier.d.ts +1 -1
  246. package/Charting3D/ChartModifiers/ResetCamera3DModifier.js +1 -2
  247. package/Charting3D/ChartModifiers/TooltipModifier3D.d.ts +122 -0
  248. package/Charting3D/ChartModifiers/TooltipModifier3D.js +427 -0
  249. package/Charting3D/I3DSurfaceOptions.d.ts +10 -0
  250. package/Charting3D/I3DSurfaceOptions.js +2 -0
  251. package/Charting3D/Model/DataSeries/BaseDataSeries3D.d.ts +2 -1
  252. package/Charting3D/Model/DataSeries/BaseDataSeries3D.js +27 -6
  253. package/Charting3D/Model/DataSeries/BaseGridDataSeries3D.d.ts +1 -1
  254. package/Charting3D/Model/DataSeries/BaseGridDataSeries3D.js +2 -2
  255. package/Charting3D/Model/DataSeries/IPointMetadata3D.d.ts +7 -2
  256. package/Charting3D/Model/DataSeries/UniformGridDataSeries3D.d.ts +8 -0
  257. package/Charting3D/Model/DataSeries/UniformGridDataSeries3D.js +12 -0
  258. package/Charting3D/Model/DataSeries/XyzDataSeries3D.d.ts +2 -2
  259. package/Charting3D/Model/DataSeries/XyzDataSeries3D.js +1 -1
  260. package/Charting3D/Vector3.d.ts +5 -0
  261. package/Charting3D/Vector3.js +7 -0
  262. package/Charting3D/Visuals/Annotations/TooltipSvgAnnotation3D.d.ts +88 -0
  263. package/Charting3D/Visuals/Annotations/TooltipSvgAnnotation3D.js +291 -0
  264. package/Charting3D/Visuals/Axis/AxisBase3D.d.ts +29 -3
  265. package/Charting3D/Visuals/Axis/AxisBase3D.js +46 -18
  266. package/Charting3D/Visuals/Axis/AxisBase3DLabelStyle.js +2 -1
  267. package/Charting3D/Visuals/Axis/AxisCubeEntity.d.ts +0 -4
  268. package/Charting3D/Visuals/Axis/AxisCubeEntity.js +3 -6
  269. package/Charting3D/Visuals/Axis/IAxisDescriptor.d.ts +2 -2
  270. package/Charting3D/Visuals/Axis/IAxisDescriptor.js +2 -2
  271. package/Charting3D/Visuals/Axis/NumericAxis3D.d.ts +3 -2
  272. package/Charting3D/Visuals/Axis/NumericAxis3D.js +7 -3
  273. package/Charting3D/Visuals/Primitives/BaseSceneEntity3D.d.ts +41 -30
  274. package/Charting3D/Visuals/Primitives/BaseSceneEntity3D.js +78 -26
  275. package/Charting3D/Visuals/Primitives/CrosshairLinesSceneEntity.d.ts +47 -0
  276. package/Charting3D/Visuals/Primitives/CrosshairLinesSceneEntity.js +106 -0
  277. package/Charting3D/Visuals/Primitives/EntityIdProvider.d.ts +29 -0
  278. package/Charting3D/Visuals/Primitives/EntityIdProvider.js +28 -0
  279. package/Charting3D/Visuals/Primitives/PointLine3DSceneEntity.d.ts +51 -0
  280. package/Charting3D/Visuals/Primitives/PointLine3DSceneEntity.js +190 -0
  281. package/Charting3D/Visuals/Primitives/RenderableSeriesSceneEntity.d.ts +12 -0
  282. package/Charting3D/Visuals/Primitives/RenderableSeriesSceneEntity.js +14 -0
  283. package/Charting3D/Visuals/Primitives/ScatterPointsSceneEntity.d.ts +11 -0
  284. package/Charting3D/Visuals/Primitives/ScatterPointsSceneEntity.js +23 -2
  285. package/Charting3D/Visuals/Primitives/SurfaceMeshSceneEntity.d.ts +3 -0
  286. package/Charting3D/Visuals/Primitives/SurfaceMeshSceneEntity.js +17 -1
  287. package/Charting3D/Visuals/RenderableSeries/BaseRenderableSeries3D.d.ts +21 -1
  288. package/Charting3D/Visuals/RenderableSeries/BaseRenderableSeries3D.js +78 -12
  289. package/Charting3D/Visuals/RenderableSeries/Constants.d.ts +2 -0
  290. package/Charting3D/Visuals/RenderableSeries/Constants.js +2 -0
  291. package/Charting3D/Visuals/RenderableSeries/ESeriesType.d.ts +2 -1
  292. package/Charting3D/Visuals/RenderableSeries/ESeriesType.js +1 -0
  293. package/Charting3D/Visuals/RenderableSeries/HitTestInfo3D.d.ts +37 -0
  294. package/Charting3D/Visuals/RenderableSeries/HitTestInfo3D.js +22 -0
  295. package/Charting3D/Visuals/RenderableSeries/PointLineRenderableSeries3D.d.ts +64 -0
  296. package/Charting3D/Visuals/RenderableSeries/PointLineRenderableSeries3D.js +105 -0
  297. package/Charting3D/Visuals/RenderableSeries/SeriesInfo3D.d.ts +51 -0
  298. package/Charting3D/Visuals/RenderableSeries/SeriesInfo3D.js +32 -0
  299. package/Charting3D/Visuals/RenderableSeries/SurfaceMeshSeriesInfo3D.d.ts +15 -0
  300. package/Charting3D/Visuals/RenderableSeries/SurfaceMeshSeriesInfo3D.js +112 -0
  301. package/Charting3D/Visuals/RenderableSeries/XyzSeriesInfo3D.d.ts +20 -0
  302. package/Charting3D/Visuals/RenderableSeries/XyzSeriesInfo3D.js +60 -0
  303. package/Charting3D/Visuals/RootSceneEntity.d.ts +0 -4
  304. package/Charting3D/Visuals/RootSceneEntity.js +3 -8
  305. package/Charting3D/Visuals/SciChart3DRenderer.d.ts +1 -0
  306. package/Charting3D/Visuals/SciChart3DRenderer.js +26 -0
  307. package/Charting3D/Visuals/SciChart3DSurface.d.ts +55 -7
  308. package/Charting3D/Visuals/SciChart3DSurface.js +136 -13
  309. package/Charting3D/Visuals/ViewportManager3DBase.d.ts +4 -0
  310. package/Charting3D/Visuals/ViewportManager3DBase.js +7 -1
  311. package/Charting3D/Visuals/createMaster3d.d.ts +1 -2
  312. package/Charting3D/Visuals/createMaster3d.js +81 -14
  313. package/Charting3D/Visuals/createSingle3d.js +34 -4
  314. package/Charting3D/Visuals/licenseManager3D.js +29 -25
  315. package/Core/BuildStamp.d.ts +1 -1
  316. package/Core/BuildStamp.js +2 -2
  317. package/Core/DeletableEntity.d.ts +34 -0
  318. package/Core/DeletableEntity.js +138 -0
  319. package/Core/Globals.d.ts +11 -0
  320. package/Core/Globals.js +13 -0
  321. package/Core/Guard.d.ts +6 -0
  322. package/Core/Guard.js +10 -0
  323. package/Core/Mouse/MouseManager.d.ts +23 -0
  324. package/Core/Mouse/MouseManager.js +53 -0
  325. package/Core/Telemetry.js +4 -6
  326. package/_wasm/scichart.browser.js +1 -1
  327. package/_wasm/scichart2d.data +0 -0
  328. package/_wasm/scichart2d.js +4 -294
  329. package/_wasm/scichart2d.wasm +0 -0
  330. package/_wasm/scichart3d.data +0 -0
  331. package/_wasm/scichart3d.js +4 -294
  332. package/_wasm/scichart3d.wasm +0 -0
  333. package/index.d.ts +42 -2
  334. package/index.dev.js +68876 -0
  335. package/index.js +81 -27
  336. package/index.min.js +1 -1
  337. package/package.json +3 -4
  338. package/types/ChartModifierType.d.ts +2 -0
  339. package/types/ChartModifierType.js +2 -0
  340. package/types/DefaultRenderLayer.d.ts +9 -8
  341. package/types/DefaultRenderLayer.js +9 -8
  342. package/types/NumberArray.d.ts +1 -0
  343. package/types/NumberArray.js +12 -1
  344. package/types/SceneEntityType.d.ts +13 -5
  345. package/types/SceneEntityType.js +13 -5
  346. package/types/TSciChart.d.ts +37 -8
  347. package/types/TSciChart3D.d.ts +126 -7
  348. package/types/licensingClasses.d.ts +2 -1
  349. package/types/licensingClasses.js +1 -0
  350. package/utils/MemoryUsageHelper.d.ts +92 -0
  351. package/utils/MemoryUsageHelper.js +221 -0
  352. package/utils/array.d.ts +8 -0
  353. package/utils/array.js +58 -1
  354. package/utils/colorUtil.d.ts +7 -0
  355. package/utils/colorUtil.js +13 -1
  356. package/utils/logger.d.ts +2 -0
  357. package/utils/logger.js +11 -0
  358. package/utils/parseColor.js +19 -4
@@ -86,9 +86,9 @@ var translate_1 = require("../../utils/translate");
86
86
  var ChartModifierBase_1 = require("../ChartModifiers/ChartModifierBase");
87
87
  var BatchRenderContext_1 = require("../Drawing/BatchRenderContext");
88
88
  var BrushCache_1 = require("../Drawing/BrushCache");
89
- var RenderContext2D_1 = require("../Drawing/RenderContext2D");
90
89
  var RenderSurface_1 = require("../Drawing/RenderSurface");
91
90
  var SolidBrushCache_1 = require("../Drawing/SolidBrushCache");
91
+ var WebGlRenderContext2D_1 = require("../Drawing/WebGlRenderContext2D");
92
92
  var LayoutManager_1 = require("../LayoutManager/LayoutManager");
93
93
  var SciChartRenderer_1 = require("../Services/SciChartRenderer");
94
94
  var AdornerLayer_1 = require("./Annotations/AdornerLayer");
@@ -111,6 +111,8 @@ var SciChartDefaults_1 = require("./SciChartDefaults");
111
111
  var ChartTitleRenderer_1 = require("../Services/ChartTitleRenderer");
112
112
  var TextStyle_1 = require("../../types/TextStyle");
113
113
  var TextPosition_1 = require("../../types/TextPosition");
114
+ var Globals_1 = require("../../Core/Globals");
115
+ var createMaster3d_1 = require("../../Charting3D/Visuals/createMaster3d");
114
116
  exports.sciChartConfig = {};
115
117
  /**
116
118
  * @summary The {@link SciChartSurface} is the root 2D Chart control in SciChart's High Performance Real-time
@@ -143,10 +145,9 @@ var SciChartSurface = /** @class */ (function (_super) {
143
145
  var _a, _b, _c, _d, _e;
144
146
  _this = _super.call(this, webAssemblyContext, options === null || options === void 0 ? void 0 : options.canvases) || this;
145
147
  /**
146
- * An event handler which notifies its subscribers when a render operation has finished. Use this
147
- * to time render performance, or to update elements of the chart or your UI on redraw.
148
+ * Used internally - the {@link RenderContext2D} for drawing
148
149
  */
149
- _this.rendered = new EventHandler_1.EventHandler();
150
+ //public renderContext2D: RenderContext2D;
150
151
  /**
151
152
  * An event handler which notifies its subscribers when a render operation starts. Use this
152
153
  * to update elements of the chart for the current render. Any updates made here will not trigger a subsequent render.
@@ -234,9 +235,9 @@ var SciChartSurface = /** @class */ (function (_super) {
234
235
  _this.chartTitleRendererProperty = new ChartTitleRenderer_1.ChartTitleRenderer(_this.webAssemblyContext2D);
235
236
  _this.layoutManager = new LayoutManager_1.LayoutManager();
236
237
  // TODO: remove this
237
- if (_this.domCanvas2D) {
238
- _this.renderContext2D = new RenderContext2D_1.RenderContext2D(_this.domCanvas2D);
239
- }
238
+ //if (this.domCanvas2D) {
239
+ // this.renderContext2D = new RenderContext2D(this.domCanvas2D);
240
+ //}
240
241
  // Setup series
241
242
  _this.detachSeries = _this.detachSeries.bind(_this);
242
243
  _this.attachSeries = _this.attachSeries.bind(_this);
@@ -261,21 +262,6 @@ var SciChartSurface = /** @class */ (function (_super) {
261
262
  };
262
263
  _this.xAxes.collectionChanged.subscribe(function (arg) { return handler(arg, true); });
263
264
  _this.yAxes.collectionChanged.subscribe(function (arg) { return handler(arg, false); });
264
- // Setup annotations
265
- _this.detachAnnotation = _this.detachAnnotation.bind(_this);
266
- _this.attachAnnotation = _this.attachAnnotation.bind(_this);
267
- _this.annotations = new ObservableArray_1.ObservableArray();
268
- _this.modifierAnnotations = new ObservableArray_1.ObservableArray();
269
- _this.annotations.collectionChanged.subscribe(function (arg) {
270
- var _a, _b;
271
- (_a = arg.getOldItems()) === null || _a === void 0 ? void 0 : _a.forEach(function (a) { return _this.detachAnnotation(a); });
272
- (_b = arg.getNewItems()) === null || _b === void 0 ? void 0 : _b.forEach(function (a) { return _this.attachAnnotation(a); });
273
- });
274
- _this.modifierAnnotations.collectionChanged.subscribe(function (arg) {
275
- var _a, _b;
276
- (_a = arg.getOldItems()) === null || _a === void 0 ? void 0 : _a.forEach(function (a) { return _this.detachAnnotation(a); });
277
- (_b = arg.getNewItems()) === null || _b === void 0 ? void 0 : _b.forEach(function (a) { return _this.attachAnnotation(a); });
278
- });
279
265
  _this.adornerLayer = new AdornerLayer_1.AdornerLayer(_this);
280
266
  _this.solidBrushCacheViewportBorder = new SolidBrushCache_1.SolidBrushCache(webAssemblyContext);
281
267
  _this.solidBrushCacheCanvasBorder = new SolidBrushCache_1.SolidBrushCache(webAssemblyContext);
@@ -308,6 +294,13 @@ var SciChartSurface = /** @class */ (function (_super) {
308
294
  });
309
295
  }
310
296
  };
297
+ SciChartSurface.disposeSharedWasmContext = function () {
298
+ if (Globals_1.sciChart3DDestinations.length === 0 && Globals_1.sciChartDestinations.length === 0) {
299
+ (0, createMaster_1.disposeMultiChart)();
300
+ (0, createMaster3d_1.disposeMultiChart3d)();
301
+ }
302
+ _super.disposeSharedWasmContext.call(this);
303
+ };
311
304
  /**
312
305
  * Performs a similar operation to {@link SciChartSurface.create} but uses a dedicated WebAssembly context for this chart, and draws directly to the target canvas
313
306
  * This provides better performance for a single chart, but there is a limit (16) to how many you can have on one page.
@@ -641,7 +634,7 @@ var SciChartSurface = /** @class */ (function (_super) {
641
634
  * @inheritDoc
642
635
  */
643
636
  SciChartSurface.prototype.changeViewportSize = function (pixelWidth, pixelHeight) {
644
- if (!pixelWidth || !pixelHeight) {
637
+ if (!pixelWidth || !pixelHeight || this.isDeleted) {
645
638
  return;
646
639
  }
647
640
  // Changing the viewportSize
@@ -675,7 +668,7 @@ var SciChartSurface = /** @class */ (function (_super) {
675
668
  */
676
669
  SciChartSurface.prototype.invalidateElement = function () {
677
670
  // When isSuspended (see suspendUpdates() function) ignore drawing
678
- if (this.isSuspended) {
671
+ if (this.isSuspended || this.isDeleted) {
679
672
  // Logger.log("SciChartSurface.isSuspended = true. Ignoring invalidateElement() call");
680
673
  return;
681
674
  }
@@ -685,6 +678,8 @@ var SciChartSurface = /** @class */ (function (_super) {
685
678
  };
686
679
  // Step_5: Get context and pass drawing to SciChartRenderer
687
680
  SciChartSurface.prototype.doDrawingLoop = function (context) {
681
+ if (this.isDeleted)
682
+ return;
688
683
  context = context !== null && context !== void 0 ? context : this.renderSurface.getRenderContext();
689
684
  this.currentWebGlRenderContextProperty = context;
690
685
  try {
@@ -701,6 +696,9 @@ var SciChartSurface = /** @class */ (function (_super) {
701
696
  this.preRender.raiseEvent(context);
702
697
  }
703
698
  catch (err) {
699
+ if (err === null || err === void 0 ? void 0 : err.message) {
700
+ console.error(err === null || err === void 0 ? void 0 : err.message);
701
+ }
704
702
  console.error(err);
705
703
  }
706
704
  finally {
@@ -716,52 +714,50 @@ var SciChartSurface = /** @class */ (function (_super) {
716
714
  (0, NativeObject_1.freeCache)(this.webAssemblyContext2D).delete();
717
715
  }
718
716
  else if (this.domChartRoot) {
719
- console.error("Error from chart in div ".concat(this.domChartRoot.id), err);
717
+ console.error("Error from chart in div ".concat(this.domChartRoot.id, ":"), err);
720
718
  }
721
719
  else {
722
720
  // Surface the error for tests
723
721
  throw err;
724
722
  }
725
723
  }
726
- this.currentWebGlRenderContextProperty = undefined;
727
724
  };
728
725
  /**
729
726
  * @inheritDoc
730
727
  */
731
728
  SciChartSurface.prototype.delete = function (clearHtml) {
732
729
  if (clearHtml === void 0) { clearHtml = true; }
733
- _super.prototype.delete.call(this);
730
+ if (this.isDeleted) {
731
+ try {
732
+ if (process.env.NODE_ENV !== "production") {
733
+ console.warn("Trying to delete the surface with ID = \"".concat(this.id, ")\", which has already been deleted!"));
734
+ }
735
+ }
736
+ catch (err) {
737
+ console.warn(err);
738
+ }
739
+ return;
740
+ }
734
741
  for (var _i = 0, _a = this.subChartsProperty; _i < _a.length; _i++) {
735
742
  var chart = _a[_i];
736
743
  chart.delete();
737
744
  }
738
745
  this.subChartsProperty = [];
746
+ this.layoutManagerProperty.sciChartSurface = undefined;
747
+ this.layoutManagerProperty = undefined;
739
748
  this.renderableSeries.asArray().forEach(function (rs) { return rs.delete(); });
740
749
  this.renderableSeries.clear();
741
750
  this.xAxes.asArray().forEach(function (xAxis) { return xAxis.delete(); });
742
751
  this.yAxes.asArray().forEach(function (yAxis) { return yAxis.delete(); });
743
- this.modifierAnnotations.asArray().forEach(function (annotation) { return annotation.delete(); });
744
- this.annotations.asArray().forEach(function (annotation) { return annotation.delete(); });
745
752
  this.solidBrushCacheViewportBorder = (0, Deleter_1.deleteSafe)(this.solidBrushCacheViewportBorder);
746
753
  this.solidBrushCacheCanvasBorder = (0, Deleter_1.deleteSafe)(this.solidBrushCacheCanvasBorder);
747
754
  this.watermarkProperties = (0, Deleter_1.deleteSafe)(this.watermarkProperties);
748
755
  this.watermarkPropertyPosition = (0, Deleter_1.deleteSafe)(this.watermarkPropertyPosition);
749
- this.chartModifiers.asArray().forEach(function (chm) { return chm.delete(); });
750
756
  this.chartTitleRendererProperty = (0, Deleter_1.deleteSafe)(this.chartTitleRenderer);
751
- if (clearHtml && this.domChartRoot) {
752
- var style = this.domChartRoot.style;
753
- if (style) {
754
- style.background = "";
755
- style.position = "";
756
- }
757
- if (this.domChartRoot.hasOwnProperty("replaceChildren")) {
758
- // @ts-ignore
759
- this.domChartRoot.replaceChildren();
760
- }
761
- else {
762
- this.domChartRoot.innerHTML = "";
763
- }
764
- }
757
+ this.sciChartRenderer = undefined;
758
+ this.renderSurface = undefined;
759
+ this.clearRootElement(clearHtml);
760
+ _super.prototype.delete.call(this);
765
761
  };
766
762
  /**
767
763
  * @inheritDoc
@@ -769,8 +765,6 @@ var SciChartSurface = /** @class */ (function (_super) {
769
765
  SciChartSurface.prototype.onDpiChanged = function (args) {
770
766
  var _a, _b;
771
767
  this.renderableSeries.asArray().forEach(function (rs) { return rs.onDpiChanged(args); });
772
- this.annotations.asArray().forEach(function (a) { return a.onDpiChanged(args); });
773
- this.modifierAnnotations.asArray().forEach(function (a) { return a.onDpiChanged(args); });
774
768
  this.xAxes.asArray().forEach(function (a) { return a.onDpiChanged(); });
775
769
  this.yAxes.asArray().forEach(function (a) { return a.onDpiChanged(); });
776
770
  // Force a viewport size change as size-changed may not fire when parent div has width, height
@@ -1196,7 +1190,8 @@ var SciChartSurface = /** @class */ (function (_super) {
1196
1190
  loader: this.loaderJson,
1197
1191
  drawSeriesBehindAxis: this.drawSeriesBehindAxis,
1198
1192
  disableAspect: this.disableAspect,
1199
- autoColorMode: this.autoColorMode
1193
+ autoColorMode: this.autoColorMode,
1194
+ touchAction: this.touchActionProperty
1200
1195
  };
1201
1196
  var definition = {
1202
1197
  surface: options,
@@ -1244,6 +1239,9 @@ var SciChartSurface = /** @class */ (function (_super) {
1244
1239
  if (options === null || options === void 0 ? void 0 : options.titleStyle) {
1245
1240
  this.titleStyle = options.titleStyle;
1246
1241
  }
1242
+ if (options === null || options === void 0 ? void 0 : options.touchAction) {
1243
+ this.touchActionProperty = options.touchAction;
1244
+ }
1247
1245
  };
1248
1246
  /**
1249
1247
  * @inheritDoc
@@ -1338,6 +1336,7 @@ var SciChartSurface = /** @class */ (function (_super) {
1338
1336
  else {
1339
1337
  this.doDrawingLoop();
1340
1338
  }
1339
+ this.currentWebGlRenderContextProperty = (0, Deleter_1.deleteSafe)(this.currentWebGlRenderContext);
1341
1340
  };
1342
1341
  SciChartSurface.prototype.detachSeries = function (renderableSeries) {
1343
1342
  if (renderableSeries.type === SeriesType_1.ESeriesType.StackedColumnSeries ||
@@ -1396,8 +1395,7 @@ var SciChartSurface = /** @class */ (function (_super) {
1396
1395
  this.invalidateElement();
1397
1396
  };
1398
1397
  SciChartSurface.prototype.detachAxis = function (axis) {
1399
- axis.invalidateParentCallback = undefined;
1400
- axis.parentSurface = undefined;
1398
+ axis.onDetach();
1401
1399
  this.invalidateElement();
1402
1400
  };
1403
1401
  SciChartSurface.prototype.attachAxis = function (axis, isXAxis) {
@@ -1418,21 +1416,6 @@ var SciChartSurface = /** @class */ (function (_super) {
1418
1416
  axis.invalidateParentCallback = this.invalidateElement;
1419
1417
  this.invalidateElement();
1420
1418
  };
1421
- SciChartSurface.prototype.detachAnnotation = function (annotation) {
1422
- annotation.onDetach();
1423
- annotation.invalidateParentCallback = undefined;
1424
- annotation.parentSurface = undefined;
1425
- this.invalidateElement();
1426
- };
1427
- SciChartSurface.prototype.attachAnnotation = function (annotation) {
1428
- if (annotation.invalidateParentCallback) {
1429
- throw new Error("Invalid operation in sciChartSurface.attachAnnotation, this annotation has already been attached to a SciChartSurface. Please detach it from a SciChartSurface before attaching to another");
1430
- }
1431
- annotation.parentSurface = this;
1432
- annotation.invalidateParentCallback = this.invalidateElement;
1433
- annotation.onAttach(this);
1434
- this.invalidateElement();
1435
- };
1436
1419
  SciChartSurface.prototype.onAttachSubSurface = function (subSurface) {
1437
1420
  this.chartModifiers.asArray().forEach(function (modifier) {
1438
1421
  modifier.onAttachSubSurface(subSurface);
@@ -1730,11 +1713,11 @@ var SciChartSubSurface = /** @class */ (function (_super) {
1730
1713
  SciChartSubSurface.prototype.delete = function (clearHtml) {
1731
1714
  if (clearHtml === void 0) { clearHtml = true; }
1732
1715
  // Don't ever clear html on the parent here as it kills the drawing for all subcharts.
1733
- _super.prototype.delete.call(this, false);
1734
1716
  if (clearHtml && this.domChartRoot.contains(this.domSvgContainer)) {
1735
1717
  this.domChartRoot.removeChild(this.domSvgContainer);
1736
1718
  }
1737
1719
  this.backgroundFillBrushCache = (0, Deleter_1.deleteSafe)(this.backgroundFillBrushCache);
1720
+ _super.prototype.delete.call(this, false);
1738
1721
  };
1739
1722
  SciChartSubSurface.prototype.toJSON = function (excludeData) {
1740
1723
  var _a;
@@ -1822,7 +1805,9 @@ var SciChartSubSurface = /** @class */ (function (_super) {
1822
1805
  if (alphaEnabled === void 0) { alphaEnabled = true; }
1823
1806
  this.backgroundProperty = background;
1824
1807
  if (!this.isTransparent) {
1825
- var renderContext = this.renderSurface.getRenderContext();
1808
+ // const renderContext = this.renderSurface.getRenderContext();
1809
+ // This is probably an unnecessary change, and mostly here to prevent a memory usage debug warning
1810
+ var renderContext = new WebGlRenderContext2D_1.WebGlRenderContext2D(this.webAssemblyContext2D, this.renderSurface.viewportSize, this.renderSurface.canvasId);
1826
1811
  var nativeContext = renderContext.getNativeContext();
1827
1812
  var _a = this.parentSurface.renderSurface.viewportSize, width = _a.width, height = _a.height;
1828
1813
  nativeContext.SetClipRect(this.adjustedPadding.left, this.adjustedPadding.top, width - this.adjustedPadding.right - this.adjustedPadding.left, height - this.adjustedPadding.bottom - this.adjustedPadding.top);
@@ -1840,6 +1825,7 @@ var SciChartSubSurface = /** @class */ (function (_super) {
1840
1825
  catch (error) {
1841
1826
  performanceWarnings_1.performanceWarnings.subchartBackgroundNotSimpleColor.warn();
1842
1827
  }
1828
+ renderContext.delete();
1843
1829
  }
1844
1830
  };
1845
1831
  SciChartSubSurface.prototype.updateWrapper = function (subChartPosition) {
@@ -1,9 +1,11 @@
1
+ import { DeletableEntity } from "../../Core/DeletableEntity";
1
2
  import { EventHandler } from "../../Core/EventHandler";
2
3
  import { IDeletable } from "../../Core/IDeletable";
3
4
  import { MouseManager } from "../../Core/Mouse/MouseManager";
4
5
  import { ObservableArray } from "../../Core/ObservableArray";
5
6
  import { PropertyChangedEventArgs } from "../../Core/PropertyChangedEventArgs";
6
7
  import { Rect } from "../../Core/Rect";
8
+ import { Thickness } from "../../Core/Thickness";
7
9
  import { EThemeProviderType } from "../../types/ThemeProviderType";
8
10
  import { TSciChart } from "../../types/TSciChart";
9
11
  import { TSciChart3D } from "../../types/TSciChart3D";
@@ -11,7 +13,9 @@ import { TSciChartSurfaceCanvases } from "../../types/TSciChartSurfaceCanvases";
11
13
  import { IChartModifierBase } from "../ChartModifiers/ChartModifierBase";
12
14
  import { IThemeable } from "../Themes/IThemeable";
13
15
  import { IThemePartial, IThemeProvider } from "../Themes/IThemeProvider";
14
- import { I2DSurfaceOptions } from "./I2DSurfaceOptions";
16
+ import { AdornerLayer } from "./Annotations/AdornerLayer";
17
+ import { IAnnotation } from "./Annotations/IAnnotation";
18
+ import { AxisCore } from "./Axis/AxisCore";
15
19
  import { ISciChartLoader } from "./loader";
16
20
  import { INotifyOnDpiChanged, TDpiChangedEventArgs } from "./TextureManager/DpiHelper";
17
21
  import { ISuspendable, IUpdateSuspender } from "./UpdateSuspender";
@@ -19,7 +23,7 @@ export declare type TSciChartDestination = {
19
23
  canvasElementId: string;
20
24
  width: number;
21
25
  height: number;
22
- sciChartSurface: SciChartSurfaceBase;
26
+ sciChartSurface: ISciChartSurfaceBase;
23
27
  };
24
28
  export declare type TSciChartConfig = {
25
29
  wasmUrl?: string;
@@ -34,7 +38,7 @@ export interface ISurfaceOptionsBase {
34
38
  */
35
39
  id?: string;
36
40
  /**
37
- * Optional - The theme applied to the {@link SciChartSurface} on startup
41
+ * Optional - The theme applied to the {@link SciChartSurfaceBase} on startup
38
42
  * @remarks see {@link IThemeProvider} for properties which can affect SciChart theme. Two default
39
43
  * themes are included out of the box {@link SciChartJSLightTheme} and {@link SciChartJSDarkTheme}.
40
44
  * Custom themes may be created by implementing {@link IThemeProvider}
@@ -50,6 +54,29 @@ export interface ISurfaceOptionsBase {
50
54
  type: string;
51
55
  options?: any;
52
56
  };
57
+ /**
58
+ * Sets a `touch-action` property to the canvas style.
59
+ * Useful if touch interactions in browser should be configured.
60
+ * https://developer.mozilla.org/en-US/docs/Web/CSS/touch-action
61
+ *
62
+ * @remarks By default a chart will use `touch-action: none` to prevent the default browser behavior.
63
+ */
64
+ touchAction?: string;
65
+ /**
66
+ * Optional - the width aspect ratio of the {@link SciChartSurfaceBase}. By default SciChart will scale to fit the parent Div.
67
+ * However if height of the div is not provided it will use width/height aspect ratio to calculate the height. The default ratio is 3/2.
68
+ */
69
+ widthAspect?: number;
70
+ /**
71
+ * Optional - the height aspect ratio of the {@link SciChartSurfaceBase}. By default SciChart will scale to fit the parent Div.
72
+ * However if height of the div is not provided it will use width/height aspect ratio to calculate the height. The default ratio is 3/2.
73
+ */
74
+ heightAspect?: number;
75
+ /**
76
+ * Optional - the option of disabling / enabling scaling of the {@link SciChartSurfaceBase}.
77
+ * If false - the {@link SciChartSurfaceBase} will take the height and width of parent div without scaling.
78
+ */
79
+ disableAspect?: boolean;
53
80
  }
54
81
  export declare const DebugForDpi: boolean;
55
82
  /**
@@ -60,8 +87,13 @@ export declare const DebugForDpi: boolean;
60
87
  * to use the SciChartSurface and create a 2D or 3D {@link https://www.scichart.com/javascript-chart-features | JavaScript Chart}
61
88
  */
62
89
  export interface ISciChartSurfaceBase extends IDeletable, IThemeable {
90
+ readonly id: string;
91
+ readonly domChartRoot: HTMLDivElement;
92
+ readonly domDivContainer: HTMLDivElement;
63
93
  readonly domCanvas2D: HTMLCanvasElement;
64
94
  readonly themeProvider: IThemeProvider;
95
+ readonly isDeleted: boolean;
96
+ readonly otherSurfaces: ISciChartSurfaceBase[];
65
97
  /**
66
98
  * Changes the Viewport Size of the {@link SciChartSurfaceBase}
67
99
  * @param width
@@ -72,6 +104,13 @@ export interface ISciChartSurfaceBase extends IDeletable, IThemeable {
72
104
  * Add an IDeleteable object to the surface which will have its delete method called when the surface is deleted
73
105
  */
74
106
  addDeletable(deletable: IDeletable): void;
107
+ invalidateElement(): void;
108
+ delete(clearHtml?: boolean): void;
109
+ /**
110
+ * An event handler which notifies its subscribers when a render operation has finished. Use this
111
+ * to time render performance, or to update elements of the chart or your UI on redraw.
112
+ */
113
+ rendered: EventHandler<void>;
75
114
  }
76
115
  /**
77
116
  * Enum constants to specify SciChartSurface type
@@ -93,7 +132,7 @@ export declare enum ESurfaceType {
93
132
  * See derived types {@link SciChartSurface} (2D Charts) and {@link SciChart3DSurface} (3D Charts) for more specific instructions on how
94
133
  * to use the SciChartSurface and create a 2D or 3D {@link https://www.scichart.com/javascript-chart-features | JavaScript Chart}
95
134
  */
96
- export declare abstract class SciChartSurfaceBase implements ISciChartSurfaceBase, ISuspendable, INotifyOnDpiChanged {
135
+ export declare abstract class SciChartSurfaceBase extends DeletableEntity implements ISciChartSurfaceBase, ISuspendable, INotifyOnDpiChanged {
97
136
  /**
98
137
  * Gets or sets the application-wide default theme. See {@link IThemeProvider} for details
99
138
  */
@@ -110,11 +149,28 @@ export declare abstract class SciChartSurfaceBase implements ISciChartSurfaceBas
110
149
  * chart parts are automatically anti-aliased
111
150
  */
112
151
  static AntiAliasWebGlBackbuffer: boolean;
152
+ /**
153
+ * Defines a delay of the shared wasmContext auto-dispose if {@link autoDisposeWasmContext} is enabled.
154
+ */
155
+ static wasmContextDisposeTimeout: number;
156
+ /**
157
+ * Defines if the shared wasmContext ({@link TSciChart | WebAssembly Context}) should be deleted after all of the surfaces that use it are deleted.
158
+ */
159
+ static autoDisposeWasmContext: boolean;
160
+ /**
161
+ * Deletes the shared wasmContext ({@link TSciChart | WebAssembly Context}) used by the charts instantiated with {@link SciChartSurface.create} or {@link SciChart3DSurface.create}.
162
+ */
163
+ static disposeSharedWasmContext(): void;
113
164
  /**
114
165
  * Sets the runtime license key. Use for full licenses or trials only, not developer licenses.
115
166
  * @param keyCode
116
167
  */
117
168
  static setRuntimeLicenseKey(keyCode: string): void;
169
+ /**
170
+ * Causes SciChart to always use its built in community non-commercial license. This stops it attempting to look for the license wizard
171
+ * Usage of the community license constitutes acceptace of the EULA at https://scichart.com/JSCommunityEULA
172
+ */
173
+ static UseCommunityLicense(): void;
118
174
  /**
119
175
  * Sets the endpoint for validating a runtime license key with the server. Must be a relative path.
120
176
  * @default api/license
@@ -144,36 +200,68 @@ export declare abstract class SciChartSurfaceBase implements ISciChartSurfaceBas
144
200
  /**
145
201
  * The {@link HTMLDivElement} which is the dom chart root
146
202
  */
147
- readonly domChartRoot: HTMLDivElement;
203
+ domChartRoot: HTMLDivElement;
148
204
  /**
149
205
  * The {@link HTMLCanvasElement} which is the WebGL canvas that SciChart draws to
150
206
  */
151
- readonly domCanvasWebGL: HTMLCanvasElement;
207
+ domCanvasWebGL: HTMLCanvasElement;
152
208
  /**
153
209
  * The {@link HTMLCanvasElement} which is the HTML5 canvas which SciChart draws overlays (cursors, tooltips) to
154
210
  */
155
- readonly domCanvas2D: HTMLCanvasElement;
211
+ domCanvas2D: HTMLCanvasElement;
156
212
  /**
157
213
  * The {@link SVGSVGElement} which is the SVG canvas which SciChart adds elements (tooltips, annotations) to
158
214
  */
159
- readonly domSvgContainer: SVGSVGElement;
215
+ domSvgContainer: SVGSVGElement;
160
216
  /**
161
217
  * The {@link SVGSVGElement} which is the SVG adorner layer canvas, is used for annotation adorners
162
218
  */
163
- readonly domSvgAdornerLayer: SVGSVGElement;
219
+ domSvgAdornerLayer: SVGSVGElement;
164
220
  /**
165
221
  * The inner {@link HTMLDivElement} div element
166
222
  */
167
- readonly domDivContainer: HTMLDivElement;
223
+ domDivContainer: HTMLDivElement;
168
224
  /**
169
225
  * The {@link MouseManager} subscribes to mouse events on the {@link domChartRoot} and routes them to components within SciChart
170
226
  */
171
- readonly mouseManager: MouseManager;
227
+ mouseManager: MouseManager;
172
228
  /**
173
229
  * The {@link IThemeProvider} provides colors, brushes and theme information for the current {@link SciChartSurfaceBase}
174
230
  */
175
231
  /** For serialization Only. The name of the onCreated function applied by the builder api */
176
232
  onCreatedName: string;
233
+ /**
234
+ * @summary Gets the collection of {@link IAnnotation} - annotations, markers or shapes drawn over the top of a {@link SciChartSurface}
235
+ * @description A {@link SciChartSurface} can have zero to many {@link IAnnotation | Annotations}.
236
+ *
237
+ * The Annotations are drawn using our WebGL / WebAssembly rendering engine, but some use SVG for maximum configurability.
238
+ * See derived types of {@link IAnnotation} such as {@link BoxAnnotation}, {@link LineAnnotation} etc...
239
+ *
240
+ * Use this collection to add and remove Annotations to the chart.
241
+ * @remarks
242
+ * Adding an Annotation to the chart causes it to automatically redraw. Note that annotations do not pariticpate in autoranging,
243
+ * meaning a chart will zoom to fit data and chart series but not annotations
244
+ */
245
+ readonly annotations: ObservableArray<IAnnotation>;
246
+ /**
247
+ * @summary Gets the collection of {@link IAnnotation} - modifier annotations, markers or shapes drawn over the top of a {@link SciChartSurface}
248
+ * @description A {@link SciChartSurface} can have zero to many {@link IAnnotation | Annotations}.
249
+ *
250
+ * The Annotations are drawn using our WebGL / WebAssembly rendering engine, but some use SVG for maximum configurability.
251
+ * See derived types of {@link IAnnotation} such as {@link BoxAnnotation}, {@link LineAnnotation} etc...
252
+ *
253
+ * Use this collection to add and remove Modifier Annotations to the chart.
254
+ * @remarks
255
+ * Adding an Modifier Annotation to the chart causes it to automatically redraw. Note that annotations do not pariticpate in autoranging,
256
+ * meaning a chart will zoom to fit data and chart series but not annotations
257
+ */
258
+ readonly modifierAnnotations: ObservableArray<IAnnotation>;
259
+ adornerLayer: AdornerLayer;
260
+ /**
261
+ * An event handler which notifies its subscribers when a render operation has finished. Use this
262
+ * to time render performance, or to update elements of the chart or your UI on redraw.
263
+ */
264
+ rendered: EventHandler<void>;
177
265
  protected destinations: TSciChartDestination[];
178
266
  protected themeProviderProperty: IThemeProvider;
179
267
  protected previousThemeProviderProperty: IThemeProvider;
@@ -181,11 +269,12 @@ export declare abstract class SciChartSurfaceBase implements ISciChartSurfaceBas
181
269
  protected isDeletedProperty: boolean;
182
270
  protected backgroundProperty: string;
183
271
  protected idProperty: string;
272
+ protected touchActionProperty: string;
184
273
  protected widthAspect: number;
185
274
  protected heightAspect: number;
186
275
  protected disableAspect: boolean;
187
276
  protected loaderJson: any;
188
- private readonly sharedWasmContext;
277
+ private sharedWasmContext;
189
278
  private readonly suspendableIdProperty;
190
279
  private seriesViewRectProperty;
191
280
  private isAlphaEnabledProperty;
@@ -280,12 +369,23 @@ export declare abstract class SciChartSurfaceBase implements ISciChartSurfaceBas
280
369
  * engine will schedule a redraw a the next time the renderer is free.
281
370
  */
282
371
  abstract invalidateElement(): void;
372
+ abstract getSeriesViewRectPadding(scaled: boolean): Thickness;
283
373
  getMainCanvas(): HTMLCanvasElement;
284
374
  /**
285
375
  * Sets the Series View {@link Rect}, a rectangle relative to the entire size of the {@link SciChartSurfaceBase}
286
376
  * @param seriesViewRect a {@link Rect} which defines the portion of the view for drawing series
287
377
  */
288
378
  setSeriesViewRect(seriesViewRect: Rect): void;
379
+ /**
380
+ * Gets the {@link AxisCore | XAxis} which matches the axisId. Returns undefined if not axis found
381
+ * @param axisId The AxisId to search for
382
+ */
383
+ abstract getXAxisById(axisId: string): AxisCore;
384
+ /**
385
+ * Gets the {@link AxisCore | YAxis} which matches the axisId. Returns undefined if not axis found
386
+ * @param axisId The AxisId to search for
387
+ */
388
+ abstract getYAxisById(axisId: string): AxisCore;
289
389
  /**
290
390
  * Changes the Viewport Size of the {@link SciChartSurfaceBase}
291
391
  * @param width
@@ -309,7 +409,8 @@ export declare abstract class SciChartSurfaceBase implements ISciChartSurfaceBas
309
409
  */
310
410
  onDpiChanged(args: TDpiChangedEventArgs): void;
311
411
  get chartModifierGroups(): string[];
312
- protected applyOptions(options: I2DSurfaceOptions): void;
412
+ protected clearRootElement(clearHtml: boolean): void;
413
+ protected applyOptions(options: ISurfaceOptionsBase): void;
313
414
  /**
314
415
  * Detaches a {@link ChartModifierBase2D} from the {@link SciChartSurfaceBase}
315
416
  * @param chartModifier
@@ -339,6 +440,8 @@ export declare abstract class SciChartSurfaceBase implements ISciChartSurfaceBas
339
440
  protected abstract applySciChartBackground(htmlColor: string, alphaEnabled?: boolean): void;
340
441
  protected changeMasterCanvasViewportSize(wasmContext: TSciChart | TSciChart3D, pixelWidth: number, pixelHeight: number): void;
341
442
  protected changeWebGLCanvasViewportSize(wasmContext: TSciChart | TSciChart3D, pixelWidth: number, pixelHeight: number): void;
443
+ private detachAnnotation;
444
+ private attachAnnotation;
342
445
  }
343
446
  export declare const createChartDestination: (canvas: HTMLCanvasElement) => {
344
447
  canvas: HTMLCanvasElement;
@@ -346,6 +449,7 @@ export declare const createChartDestination: (canvas: HTMLCanvasElement) => {
346
449
  GetWidth(): any;
347
450
  GetID(): any;
348
451
  };
452
+ /** @ignore */
349
453
  export declare const getMasterCanvas: () => HTMLCanvasElement;
350
454
  export declare type TGetDestinationFn = (destinationId: string) => TSciChartDestination;
351
455
  export declare const copyToCanvas: (sourceCanvas: HTMLCanvasElement, getDestinationById: TGetDestinationFn) => (destinationId: string) => void;