hqchart 1.1.15874 → 1.1.15876

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.
@@ -2359,7 +2359,7 @@ this.GetExtendChartByClassNameV2=function(name){var aryChart=[];for(var i=0;i<th
2359
2359
  {var width=0;for(var i=0;i<this.ExtendChartPaint.length;++i){var item=this.ExtendChartPaint[i];if(!item)continue;if(item.ClassName=="StockChip"){if(IFrameSplitOperator.IsNumber(item.Width))width+=item.Width;}}return width;};this.GetChartPaintByClassName=function(name){var aryData=[];for(var i=0;i<this.ChartPaint.length;++i){var item=this.ChartPaint[i];if(item.ClassName==name){var frameID=null;if(item.ChartFrame)frameID=item.ChartFrame.Identify;aryData.push({IsOverlay:false,Chart:item,FrameID:frameID});}}for(var i=0;i<this.Frame.SubFrame.length;++i){var subItem=this.Frame.SubFrame[i];if(!subItem)continue;if(!IFrameSplitOperator.IsNonEmptyArray(subItem.OverlayIndex))continue;for(var j=0;j<subItem.OverlayIndex.length;++j){var item=subItem.OverlayIndex[j];for(var k=0;k<item.ChartPaint.length;++k){var chartItem=item.ChartPaint[k];if(chartItem.ClassName==name){aryData.push({IsOverlay:true,Chart:chartItem,FrameID:subItem.Frame.Identify,SubFrameID:j});}}}}return aryData;};//删除扩展画法
2360
2360
  this.DeleteExtendChart=function(data){if(data.Index>=this.ExtendChartPaint.length)return;if(this.ExtendChartPaint[data.Index]!=data.Chart)return;if(typeof data.Chart.Clear=='function')data.Chart.Clear();this.ExtendChartPaint.splice(data.Index,1);};//删除扩展画法
2361
2361
  this.DeleteExtendChartByID=function(id){for(var i=0;i<this.ExtendChartPaint.length;++i){var item=this.ExtendChartPaint[i];if(item.ID==id){this.ExtendChartPaint.splice(i,1);return true;}}return false;};//全屏提示信息 { Title:提示信息, Draw:false/true 是否立即重绘, }
2362
- this.EnableSplashScreen=function(enable,option){if(!this.ChartSplashPaint)return;this.ChartSplashPaint.EnableSplash(enable);if(option){if(option.Draw===false)return;if(option.ClearSnapshot===true)this.Frame.ScreenImageData=true;//清空缓存
2362
+ this.EnableSplashScreen=function(enable,option){if(!this.ChartSplashPaint)return;this.ChartSplashPaint.EnableSplash(enable);if(option){if(option.Draw===false)return;if(option.ClearSnapshot===true)this.Frame.ScreenImageData=null;//清空缓存
2363
2363
  }if(enable)this.DrawSplashScreen(option);else this.Draw();};this.SetSplashScreen=function(option){if(!option)return;if(IFrameSplitOperator.IsBool(option.Enable))this.ChartSplashPaint.EnableSplash(option.Enable);if(option.Title)this.ChartSplashPaint.SetTitle(option.Title);if(option.Draw)this.Draw();};this.IsEnableSplashScreen=function(){if(!this.ChartSplashPaint)return false;return this.ChartSplashPaint.IsEnableSplash;};//设置指标窗口属性 windowItem=SetOption.Windows[i], frameItem=SetOption.Frames[i];
2364
2364
  this.SetSubFrameAttribute=function(subFrame,windowItem,frameItem){if(!subFrame||!subFrame.Frame)return;var frame=subFrame.Frame;var pixelRatio=GetDevicePixelRatio();if(windowItem){if(IFrameSplitOperator.IsBool(windowItem.Modify))frame.ModifyIndex=windowItem.Modify;if(IFrameSplitOperator.IsBool(windowItem.Change))frame.ChangeIndex=windowItem.Change;if(IFrameSplitOperator.IsBool(windowItem.Close))frame.CloseIndex=windowItem.Close;if(IFrameSplitOperator.IsBool(windowItem.Overlay))frame.OverlayIndex=windowItem.Overlay;if(IFrameSplitOperator.IsBool(windowItem.Export))frame.ExportData=windowItem.Export;if(IFrameSplitOperator.IsBool(windowItem.MaxMin))frame.MaxMinWindow=windowItem.MaxMin;if(IFrameSplitOperator.IsBool(windowItem.TitleWindow))frame.TitleWindow=windowItem.TitleWindow;if(IFrameSplitOperator.IsBool(windowItem.AddIndexWindow))frame.AddIndexWindow=windowItem.AddIndexWindow;if(IFrameSplitOperator.IsBool(windowItem.IndexHelp))frame.IndexHelp=windowItem.IndexHelp;if(IFrameSplitOperator.IsBool(windowItem.IndexAIAnalyze))frame.IndexAIAnalyze=windowItem.IndexAIAnalyze;if(IFrameSplitOperator.IsBool(windowItem.IsDrawTitleBG))frame.IsDrawTitleBG=windowItem.IsDrawTitleBG;if(IFrameSplitOperator.IsBool(windowItem.IsShowNameArrow))frame.IsShowNameArrow=windowItem.IsShowNameArrow;if(IFrameSplitOperator.IsNumber(windowItem.TitleHeight))frame.ChartBorder.TitleHeight=windowItem.TitleHeight;else windowItem.TitleHeight=frame.ChartBorder.TitleHeight;if(IFrameSplitOperator.IsBool(windowItem.IsShowTitleArrow))frame.IsShowTitleArrow=windowItem.IsShowTitleArrow;if(IFrameSplitOperator.IsNumber(windowItem.TitleArrowType))frame.TitleArrowType=windowItem.TitleArrowType;if(IFrameSplitOperator.IsBool(windowItem.IsShowIndexName))frame.IsShowIndexName=windowItem.IsShowIndexName;if(IFrameSplitOperator.IsBool(windowItem.IsSinlgeLine))frame.IsSinlgeLine=windowItem.IsSinlgeLine;if(IFrameSplitOperator.IsBool(windowItem.IsShowOverlayIndexName))frame.IsShowOverlayIndexName=windowItem.IsShowOverlayIndexName;if(IFrameSplitOperator.IsNumber(windowItem.IndexParamSpace))frame.IndexParamSpace=windowItem.IndexParamSpace;if(IFrameSplitOperator.IsNumber(windowItem.IndexTitleSpace))frame.IndexTitleSpace=windowItem.IndexTitleSpace;if(windowItem.OverlayIndexType){if(IFrameSplitOperator.IsNumber(windowItem.OverlayIndexType.Position))frame.OverlayIndexType.Position=windowItem.OverlayIndexType.Position;if(IFrameSplitOperator.IsNumber(windowItem.OverlayIndexType.LineSpace))frame.OverlayIndexType.LineSpace=windowItem.OverlayIndexType.LineSpace;}}if(frameItem){if(frameItem.SplitCount)frame.YSplitOperator.SplitCount=frameItem.SplitCount;//Y轴刻度线个数
2365
2365
  if(frameItem.StringFormat)frame.YSplitOperator.StringFormat=frameItem.StringFormat;//Y轴文字格式
@@ -16761,7 +16761,7 @@ if(dayItem.Text){var textWidth=this.Canvas.measureText(dayItem.Text).width;xText
16761
16761
  {yCell=rtCell.Bottom;xCell=left;}++j;}}},{key:"DrawMarkDay",value:function DrawMarkDay(dayItem,markItem,rtCell,yText){var config=this.MarkDayConfig;var radius=config.Dots.Radius;var yOffset=config.Dots.YOffset;var color=config.Dots.Color;if(markItem.Color)color=markItem.Color;if(IFrameSplitOperator.IsNumber(markItem.YOffset))yOffset=markItem.YOffset;if(IFrameSplitOperator.IsNumber(markItem.Radius))radius=markItem.Radius;var x=rtCell.Left+rtCell.Width/2;var y=yText+yOffset;this.Canvas.fillStyle=color;this.Canvas.beginPath();this.Canvas.arc(x,y,radius,0,Math.PI*2);this.Canvas.fill();}},{key:"PtInCell",value:function PtInCell(x,y){if(!IFrameSplitOperator.IsNonEmptyArray(this.AryCellRect))return null;for(var i=0;i<this.AryCellRect.length;++i){var item=this.AryCellRect[i];var rtCell=item.Rect;if(x>=rtCell.Left&&x<=rtCell.Right&&y>=rtCell.Top&&y<=rtCell.Bottom){var data={Rect:rtCell,Type:item.Type,Data:item.Data};return data;}}return null;}},{key:"OnMouseOn",value:function OnMouseOn(x,y,e){var pixelTatio=GetDevicePixelRatio();var insidePoint={X:x/pixelTatio,Y:y/pixelTatio};var uiElement;if(this.UIElement)uiElement={Left:this.UIElement.getBoundingClientRect().left,Top:this.UIElement.getBoundingClientRect().top};else uiElement={Left:null,Top:null};var bDraw=false;var cell=this.PtInCell(x,y);if(cell){bDraw=false;var selData=this.MoveOnData.Data;if(selData&&cell.Type==selData.Type){if(cell.Type===JSCHART_CALENDAR_BUTTON_ID.DAY_CELL_ID||cell.Type===JSCHART_CALENDAR_BUTTON_ID.MONTH_CELL_ID){if(cell.Data.Date!=selData.Data.Date){this.MoveOnData.Data={Type:cell.Type,Data:cell.Data};bDraw=true;}}}else{this.MoveOnData.Data={Type:cell.Type,Data:cell.Data};bDraw=true;}return{Redraw:bDraw,Cell:cell};}if(this.MoveOnData.Data){this.MoveOnData.Data=null;bDraw=true;}return{Redraw:bDraw,Cell:null};}},{key:"OnMouseDown",value:function OnMouseDown(x,y,e){var cell=this.PtInCell(x,y);if(!cell)return null;var bDraw=false;return{Type:cell.Type,Redraw:bDraw,Data:cell.Data};}},{key:"SetSelectedDay",value:function SetSelectedDay(aryData){this.ArySelectedDay=[];if(IFrameSplitOperator.IsNonEmptyArray(aryData))this.ArySelectedDay=aryData.slice();}}]);}();/********************************************************************************
16762
16762
  * 版本信息输出
16763
16763
  *
16764
- */var HQCHART_VERSION="1.1.15873";function PrintHQChartVersion(){var logo="\n\n*************************************************************************************************************************************************************************** \n* \n* :%@@- \n* :@@@@- \n* =@@@@ :#@@@ .:+#@@@#=: :=*@@@@@@#+-. *@@@@. \n* :@@@@@ .@@@@@ .#@@@@@@@@@@@- +@@@@@@@@@@@@@+ @@@@@ -%@@* \n* +@@@@% #@@@@# *@@@@@@@@@@@@@@%. =@@@@@@@@@@@@@@@- @@@@@ -@@@@+ \n* %@@@@* @@@@@+ .%@@@@@@@@@@@@@@@@%: #@@@@@@@@@@@@@@@% @@@@# *@@@@= \n* @@@@@= @@@@@- .%@@@@@@@*++*%@@@@@@% .%@@@@@@@%*+==+**= -@@@@+ #@@@@- \n* @@@@@. @@@@@. #@@@@@%= =@@@@@@* %@@@@@@#: *@@@@- :::. .-+*###+: ::: .+##+: -%%@@@@@%%%% \n* .@@@@@ .@@@@@. +@@@@@% .@@@@@@ *@@@@@@: %@@@@: +@@@@@%. :%@@@@@@@@@@: *@@@ :@@@@@* @@@@@@@@@@@@ \n* :@@@@@ :@@@@@ @@@@@% :@@@@@+ @@@@@@: %@@@@-@@@@@@@@@. @@@@@@@@@@@@@. :@@@%-@@@@@@.:@@@@@@@@@@@# \n* -@@@@% -@@@@@ =@@@@@. %@@@@% %@@@@@- %@@@@@@@@@@@@@@* %@@@@@@@@@@@@+ -@@@@@@@@@@# -@@@@@@@@@@@. \n* +@@@@%=========#@@@@% @@@@@# :@@@@@ .@@@@@% @@@@@@@@%@@@@@@@ -%+:. .#@@@@* +@@@@@@@%%@. .::+@@@@#:: \n* #@@@@@@@@@@@@@@@@@@@# .@@@@@ .@@@@@ :@@@@@. @@@@@@#. #@@@@@. -@@@@* #@@@@@@: *@@@@+ \n* %@@@@@@@@@@@@@@@@@@@+ :@@@@@ .@@@@@ -@@@@@ @@@@@+ @@@@@. :@@@@* @@@@@% #@@@@- \n* @@@@@@@@@@@@@@@@@@@@: :@@@@% :@@@@@ +@@@@% -@@@@+ @@@@@ -@@@@+ @@@@@. @@@@@. \n* .@@@@@@@@@@@@@@@@@@@@ :@@@@% -@@@@% *@@@@% #@@@@. @@@@@ .=*#%%%@@@@@= :@@@@# @@@@@. \n* -@@@@@:::::::::=@@@@@ :@@@@@ @@@@@* +@@@@% @@@@@ @@@@% -#@@@@@@@@@@@@: -@@@@* @@@@@ \n* =@@@@% =@@@@% .@@@@@ :@@@@@. -@@@@% @@@@@ .@@@@* +@@@@@@@@@@@@@@. =@@@@+ .@@@@@ \n* +@@@@# +@@@@# @@@@@# %@@@@% :@@@@@ .@@@@% =@@@@= -@@@@@*-:..%@@@@ +@@@@= :@@@@# \n* *@@@@* *@@@@* +@@@@@: #@@@@@+ .@@@@@@ :@@@@% *@@@@- @@@@@. @@@@% #@@@@: =@@@@+ \n* %@@@@= %@@@@+ @@@@@@- .%@@@@@# #@@@@@# :@@@@% #@@@@: @@@@% @@@@* %@@@@. #@@@@- \n* @@@@@- @@@@@= =@@@@@@#=...-*@@@@@@@: @@@@@@%=. :+**. :@@@@* %@@@@. .@@@@* *@@@@= @@@@@ %@@@@+ \n* .@@@@@: .@@@@@: *@@@@@@@@@@@@@@@@@@@# =@@@@@@@@%%%@@@@@@ +@@@@- @@@@@ .@@@@@: :%@@@@@- .@@@@% %@@@@@*+- \n* :@@@@@ :@@@@@ +@@@@@@@@@@@@@@@@@@@# =@@@@@@@@@@@@@@@@% %@@@@ @@@@@ @@@@@@@@@@@@@@@: -@@@@* *@@@@@@@@- \n* =@@@@@ -@@@@@ :@@@@@@@@@@@@@@@@@@@# :@@@@@@@@@@@@@@@% @@@@@ %@@@% #@@@@@@@@@#@@@@. +@@@@- .@@@@@@@@# \n* *@@@@# =@@@@% :#@@@@@@@#: :@@@@@= =@@@@@@@@@@@+. @@@@@ :@@@+ *@@@@@@@- %@@@ *@@@= =@@@@@@@* \n* =++++- -++++= .:::. .=*+: :-=+++=:. ****= .=+. .-++=: :+++ -+=: .-=+=:. \n* \n* \n* HQChart \n* Ver: ".concat(HQCHART_VERSION," \n* License: Apache License 2.0 \n* Source: https://github.com/jones2000/HQChart\n*\n************************************************************************************************************************************************************************** \n ");console.log(logo);}PrintHQChartVersion();//把给外界调用的方法暴露出来
16764
+ */var HQCHART_VERSION="1.1.15875";function PrintHQChartVersion(){var logo="\n\n*************************************************************************************************************************************************************************** \n* \n* :%@@- \n* :@@@@- \n* =@@@@ :#@@@ .:+#@@@#=: :=*@@@@@@#+-. *@@@@. \n* :@@@@@ .@@@@@ .#@@@@@@@@@@@- +@@@@@@@@@@@@@+ @@@@@ -%@@* \n* +@@@@% #@@@@# *@@@@@@@@@@@@@@%. =@@@@@@@@@@@@@@@- @@@@@ -@@@@+ \n* %@@@@* @@@@@+ .%@@@@@@@@@@@@@@@@%: #@@@@@@@@@@@@@@@% @@@@# *@@@@= \n* @@@@@= @@@@@- .%@@@@@@@*++*%@@@@@@% .%@@@@@@@%*+==+**= -@@@@+ #@@@@- \n* @@@@@. @@@@@. #@@@@@%= =@@@@@@* %@@@@@@#: *@@@@- :::. .-+*###+: ::: .+##+: -%%@@@@@%%%% \n* .@@@@@ .@@@@@. +@@@@@% .@@@@@@ *@@@@@@: %@@@@: +@@@@@%. :%@@@@@@@@@@: *@@@ :@@@@@* @@@@@@@@@@@@ \n* :@@@@@ :@@@@@ @@@@@% :@@@@@+ @@@@@@: %@@@@-@@@@@@@@@. @@@@@@@@@@@@@. :@@@%-@@@@@@.:@@@@@@@@@@@# \n* -@@@@% -@@@@@ =@@@@@. %@@@@% %@@@@@- %@@@@@@@@@@@@@@* %@@@@@@@@@@@@+ -@@@@@@@@@@# -@@@@@@@@@@@. \n* +@@@@%=========#@@@@% @@@@@# :@@@@@ .@@@@@% @@@@@@@@%@@@@@@@ -%+:. .#@@@@* +@@@@@@@%%@. .::+@@@@#:: \n* #@@@@@@@@@@@@@@@@@@@# .@@@@@ .@@@@@ :@@@@@. @@@@@@#. #@@@@@. -@@@@* #@@@@@@: *@@@@+ \n* %@@@@@@@@@@@@@@@@@@@+ :@@@@@ .@@@@@ -@@@@@ @@@@@+ @@@@@. :@@@@* @@@@@% #@@@@- \n* @@@@@@@@@@@@@@@@@@@@: :@@@@% :@@@@@ +@@@@% -@@@@+ @@@@@ -@@@@+ @@@@@. @@@@@. \n* .@@@@@@@@@@@@@@@@@@@@ :@@@@% -@@@@% *@@@@% #@@@@. @@@@@ .=*#%%%@@@@@= :@@@@# @@@@@. \n* -@@@@@:::::::::=@@@@@ :@@@@@ @@@@@* +@@@@% @@@@@ @@@@% -#@@@@@@@@@@@@: -@@@@* @@@@@ \n* =@@@@% =@@@@% .@@@@@ :@@@@@. -@@@@% @@@@@ .@@@@* +@@@@@@@@@@@@@@. =@@@@+ .@@@@@ \n* +@@@@# +@@@@# @@@@@# %@@@@% :@@@@@ .@@@@% =@@@@= -@@@@@*-:..%@@@@ +@@@@= :@@@@# \n* *@@@@* *@@@@* +@@@@@: #@@@@@+ .@@@@@@ :@@@@% *@@@@- @@@@@. @@@@% #@@@@: =@@@@+ \n* %@@@@= %@@@@+ @@@@@@- .%@@@@@# #@@@@@# :@@@@% #@@@@: @@@@% @@@@* %@@@@. #@@@@- \n* @@@@@- @@@@@= =@@@@@@#=...-*@@@@@@@: @@@@@@%=. :+**. :@@@@* %@@@@. .@@@@* *@@@@= @@@@@ %@@@@+ \n* .@@@@@: .@@@@@: *@@@@@@@@@@@@@@@@@@@# =@@@@@@@@%%%@@@@@@ +@@@@- @@@@@ .@@@@@: :%@@@@@- .@@@@% %@@@@@*+- \n* :@@@@@ :@@@@@ +@@@@@@@@@@@@@@@@@@@# =@@@@@@@@@@@@@@@@% %@@@@ @@@@@ @@@@@@@@@@@@@@@: -@@@@* *@@@@@@@@- \n* =@@@@@ -@@@@@ :@@@@@@@@@@@@@@@@@@@# :@@@@@@@@@@@@@@@% @@@@@ %@@@% #@@@@@@@@@#@@@@. +@@@@- .@@@@@@@@# \n* *@@@@# =@@@@% :#@@@@@@@#: :@@@@@= =@@@@@@@@@@@+. @@@@@ :@@@+ *@@@@@@@- %@@@ *@@@= =@@@@@@@* \n* =++++- -++++= .:::. .=*+: :-=+++=:. ****= .=+. .-++=: :+++ -+=: .-=+=:. \n* \n* \n* HQChart \n* Ver: ".concat(HQCHART_VERSION," \n* License: Apache License 2.0 \n* Source: https://github.com/jones2000/HQChart\n*\n************************************************************************************************************************************************************************** \n ");console.log(logo);}PrintHQChartVersion();//把给外界调用的方法暴露出来
16765
16765
  var _default=exports["default"]=(_jsChartInit$jsChartS={jsChartInit:JSChart.Init,jsChartStyle:JSChart.SetStyle,// IsIndexSymbol:IsIndexSymbol,
16766
16766
  // BaseIndex:BaseIndex,
16767
16767
  // ChartLine:ChartLine,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hqchart",
3
- "version": "1.1.15874",
3
+ "version": "1.1.15876",
4
4
  "description": "HQChart - H5, 微信小程序 沪深/港股/数字货币/期货/美股 K线图(kline),走势图,缩放,拖拽,十字光标,画图工具,截图,筹码图. 分析家语法,通达信语法,(麦语法),第3方数据对接",
5
5
  "main": "lib/main.js",
6
6
  "scripts": {
@@ -14759,7 +14759,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
14759
14759
  if (option)
14760
14760
  {
14761
14761
  if (option.Draw===false) return;
14762
- if (option.ClearSnapshot===true) this.Frame.ScreenImageData=true; //清空缓存
14762
+ if (option.ClearSnapshot===true) this.Frame.ScreenImageData=null; //清空缓存
14763
14763
  }
14764
14764
 
14765
14765
  if (enable) this.DrawSplashScreen(option);
@@ -177740,7 +177740,7 @@ function ChartScrollText()
177740
177740
 
177741
177741
 
177742
177742
 
177743
- var HQCHART_VERSION="1.1.15873";
177743
+ var HQCHART_VERSION="1.1.15875";
177744
177744
 
177745
177745
  function PrintHQChartVersion()
177746
177746
  {