hqchart 1.1.14718 → 1.1.14731
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/lib/umychart.vue.js +29 -53
- package/package.json +1 -1
- package/src/jscommon/umychart.js +161 -87
- package/src/jscommon/umychart.style.js +1 -1
- package/src/jscommon/umychart.uniapp.h5/umychart.uniapp.h5.js +163 -89
- package/src/jscommon/umychart.version.js +1 -1
- package/src/jscommon/umychart.vue/umychart.vue.js +163 -89
package/lib/umychart.vue.js
CHANGED
|
@@ -3678,6 +3678,7 @@ this.DrawKRange={Start:null,End:null};//当前屏K线的索引{ Start: , End:}
|
|
|
3678
3678
|
this.IsThinAKBar=true;//美国线 柱子是否是线段 (false=柱子)
|
|
3679
3679
|
this.OneLimitBarType=0;//一字板颜色类型 4个价格全部都在同一个价位上 0=使用平盘颜色 1=跟昨收比较
|
|
3680
3680
|
this.UnchangeBarType=0;//0=使用unchange color 1=和昨收比较
|
|
3681
|
+
this.EnableColorBar=false;//K线柱子是否支持自定义颜色
|
|
3681
3682
|
this.HighLowBarColor=g_JSChartResource.HighLowBarColor;this.HighLowTextConfig={FontName:g_JSChartResource.HighLowText.FontName,MaxSize:g_JSChartResource.HighLowText.MaxSize,MinSize:g_JSChartResource.HighLowText.MinSize,Color:g_JSChartResource.HighLowText.Color,//未用
|
|
3682
3683
|
MaxText:g_JSChartResource.HighLowText.MaxText};this.HLCAreaConfig={HighLineColor:g_JSChartResource.HLCArea.HighLineColor,LowLineColor:g_JSChartResource.HLCArea.LowLineColor,CloseLineColor:g_JSChartResource.HLCArea.CloseLineColor,LineWidth:g_JSChartResource.HLCArea.LineWidth,UpAreaColor:g_JSChartResource.HLCArea.UpAreaColor,DownAreaColor:g_JSChartResource.HLCArea.DownAreaColor//虚线柱子 (非交易日)
|
|
3683
3684
|
};this.VirtualBarConfig={Color:g_JSChartResource.VirtualKLine.Color,LineDash:g_JSChartResource.VirtualKLine.LineDash};//预测线配置
|
|
@@ -3742,7 +3743,7 @@ for(var i=this.Data.DataOffset,j=0;i<this.Data.Data.length&&j<xPointCount;++i,++
|
|
|
3742
3743
|
{ptMax.X=x;ptMax.Y=yHigh;ptMax.Value=data.High;ptMax.Align=j<xPointCount/2?'left':'right';}if(ptMin.Value==null||ptMin.Value>data.Low)//求最小值
|
|
3743
3744
|
{ptMin.X=x;ptMin.Y=yLow;ptMin.Value=data.Low;ptMin.Align=j<xPointCount/2?'left':'right';}if(this.ColorData)///五彩K线颜色设置
|
|
3744
3745
|
{if(i<this.ColorData.length)upColor=downColor=unchagneColor=this.ColorData[i]>0?this.UpColor:this.DownColor;else upColor=downColor=unchagneColor=this.DownColor;}var kLineOption=this.GetCustomKLine(data);if(data.IsNonTrade)//非交易日 绘制虚线柱子
|
|
3745
|
-
{this.DrawVirtualBar(data,dataWidth,x,y,left,right,yLow,yHigh,yOpen,yClose,isHScreen);}else if(data.IsVirtual&&this.PredictionConfig.Enable){this.DrawPredictionBar(data,dataWidth,x,y,left,right,yLow,yHigh,yOpen,yClose,isHScreen);}else if(kLineOption){var barColor=kLineOption.Color;if(!barColor){if(data.Open<data.Close)barColor=upColor;else if(data.Open>data.Close)barColor=downColor;else barColor=unchagneColor;}var drawType=this.DrawType;if(IFrameSplitOperator.IsNumber(kLineOption.DrawType))drawType=kLineOption.DrawType;this.DrawKBar_Custom(data,dataWidth,barColor,drawType,kLineOption,x,y,left,right,yLow,yHigh,yOpen,yClose,border,isHScreen);}else if(this.DrawType==9&&data.ColorData){this.DrawColorKBar(data,data.ColorData,dataWidth,x,y,left,right,yLow,yHigh,yOpen,yClose,isHScreen);}else if(data.Open<data.Close)//阳线
|
|
3746
|
+
{this.DrawVirtualBar(data,dataWidth,x,y,left,right,yLow,yHigh,yOpen,yClose,isHScreen);}else if(data.IsVirtual&&this.PredictionConfig.Enable){this.DrawPredictionBar(data,dataWidth,x,y,left,right,yLow,yHigh,yOpen,yClose,isHScreen);}else if(kLineOption){var barColor=kLineOption.Color;if(!barColor){if(data.Open<data.Close)barColor=upColor;else if(data.Open>data.Close)barColor=downColor;else barColor=unchagneColor;}var drawType=this.DrawType;if(IFrameSplitOperator.IsNumber(kLineOption.DrawType))drawType=kLineOption.DrawType;this.DrawKBar_Custom(data,dataWidth,barColor,drawType,kLineOption,x,y,left,right,yLow,yHigh,yOpen,yClose,border,isHScreen);}else if((this.DrawType==9||this.EnableColorBar)&&data.ColorData){this.DrawColorKBar(data,data.ColorData,dataWidth,x,y,left,right,yLow,yHigh,yOpen,yClose,isHScreen);}else if(data.Open<data.Close)//阳线
|
|
3746
3747
|
{this.DrawKBar_Up(data,dataWidth,upColor,this.DrawType,x,y,left,right,yLow,yHigh,yOpen,yClose,isHScreen);}else if(data.Open>data.Close)//阴线
|
|
3747
3748
|
{this.DrawKBar_Down(data,dataWidth,downColor,this.DrawType,x,y,left,right,yLow,yHigh,yOpen,yClose,isHScreen);}else// 平线
|
|
3748
3749
|
{var barColor=unchagneColor;if(eventUnchangeKLine&&eventUnchangeKLine.Callback){var sendData={KItem:data,DataIndex:i,DefaultColor:barColor,BarColor:null};eventUnchangeKLine.Callback(eventUnchangeKLine,sendData,this);if(sendData.BarColor)barColor=sendData.BarColor;}this.DrawKBar_Unchagne(data,dataWidth,barColor,this.DrawType,x,y,left,right,yLow,yHigh,yOpen,yClose,isHScreen);}if(this.IsShowKTooltip&&!isHScreen)//添加tooltip区域
|
|
@@ -5688,9 +5689,12 @@ this.IsShow=true;this.IsShowClose=false;//Y轴始终显示收盘价
|
|
|
5688
5689
|
this.ClientPos=-1;this.CallAcutionXOperator;this.EnableKeyboard=false;//是否支持键盘隐藏显示
|
|
5689
5690
|
this.EnableDBClick=false;//是否允许双击显示|隐藏十字光标
|
|
5690
5691
|
this.OnChangeStatusCallback;//状态切换以后回调
|
|
5691
|
-
this.RightButton={Enable:false,Rect:null,BGColor:g_JSChartResource.CorssCursor.RightButton.BGColor,PenColor:g_JSChartResource.CorssCursor.RightButton.PenColor,Icon:g_JSChartResource.CorssCursor.RightButton.Icon};//底部按钮
|
|
5692
|
-
this.BottomButton={Enable:false,Rect:null};this.
|
|
5693
|
-
this.LeftConfig=CloneData(g_JSChartResource.CorssCursor.LeftText)
|
|
5692
|
+
this.RightButton={Enable:false,Rect:null,BGColor:g_JSChartResource.CorssCursor.RightButton.BGColor,PenColor:g_JSChartResource.CorssCursor.RightButton.PenColor,Icon:CloneData(g_JSChartResource.CorssCursor.RightButton.Icon)};//底部按钮
|
|
5693
|
+
this.BottomButton={Enable:false,Rect:null};this.BottomConfig=CloneData(g_JSChartResource.CorssCursor.BottomText);//底部输出配置
|
|
5694
|
+
this.LeftConfig=CloneData(g_JSChartResource.CorssCursor.LeftText);//左侧输出配置
|
|
5695
|
+
this.RightConfig=CloneData(g_JSChartResource.CorssCursor.RightText);//右侧输出配置
|
|
5696
|
+
this.RightOverlayConfig=CloneData(g_JSChartResource.CorssCursor.RightOverlayText);//右侧叠加指标输出配置
|
|
5697
|
+
//内部使用
|
|
5694
5698
|
this.Close=null;//收盘价格
|
|
5695
5699
|
this.Status=0;//当前状态 0=隐藏 1=显示
|
|
5696
5700
|
this.ReloadResource=function(resource){this.Font=g_JSChartResource.CorssCursorTextFont;//字体
|
|
@@ -5700,7 +5704,7 @@ this.TextColor=g_JSChartResource.CorssCursorTextColor;//文本颜色
|
|
|
5700
5704
|
this.TextBGColor=g_JSChartResource.CorssCursorBGColor;//文本背景色
|
|
5701
5705
|
this.BorderColor=g_JSChartResource.CorssCursorBorderColor;//边框颜色
|
|
5702
5706
|
this.XRangeBGColor=g_JSChartResource.CorssCursorXRangeBGColor;this.LineDash=g_JSChartResource.CorssCursorLineDash.slice();//虚线
|
|
5703
|
-
this.CorssPointConfig.Center=CloneData(g_JSChartResource.CorssCursor.CorssPoint.Center);this.CorssPointConfig.Border=CloneData(g_JSChartResource.CorssCursor.CorssPoint.Border);};this.GetCloseYPoint=function(index){if(!this.StringFormatX.Data)return null;var data=this.StringFormatX.Data;if(!data.Data||data.Data.length<=0)return null;var dataIndex=data.DataOffset+index;if(dataIndex>=data.Data.length)dataIndex=data.Data.length-1;if(dataIndex<0)return null;var klineData=data.Data[dataIndex];if(!klineData)return null;this.Close=klineData.Close;var yPoint=this.Frame.GetYFromData(this.Close);return yPoint;};this.GetMinuteCloseYPoint=function(index){if(this.EnableNewIndex&&this.CorssCursorIndex){if(!this.StringFormatX||!this.StringFormatX.GetMinuteCloseYPoint)return null;var closeData=this.StringFormatX.GetMinuteCloseYPoint(this.CorssCursorIndex);if(!closeData)return null;this.Close=closeData.Price;return closeData.Y;}else{if(!IFrameSplitOperator.IsNumber(index))return null;index=parseInt(index.toFixed(0));//index=parseInt(index);
|
|
5707
|
+
this.RightButton.BGColor=g_JSChartResource.CorssCursor.RightButton.BGColor;this.RightButton.PenColor=g_JSChartResource.CorssCursor.RightButton.PenColor;this.RightButton.Icon=CloneData(g_JSChartResource.CorssCursor.RightButton.Icon);this.RightOverlayConfig=CloneData(g_JSChartResource.CorssCursor.RightOverlayText);this.CorssPointConfig.Center=CloneData(g_JSChartResource.CorssCursor.CorssPoint.Center);this.CorssPointConfig.Border=CloneData(g_JSChartResource.CorssCursor.CorssPoint.Border);};this.GetCloseYPoint=function(index){if(!this.StringFormatX.Data)return null;var data=this.StringFormatX.Data;if(!data.Data||data.Data.length<=0)return null;var dataIndex=data.DataOffset+index;if(dataIndex>=data.Data.length)dataIndex=data.Data.length-1;if(dataIndex<0)return null;var klineData=data.Data[dataIndex];if(!klineData)return null;this.Close=klineData.Close;var yPoint=this.Frame.GetYFromData(this.Close);return yPoint;};this.GetMinuteCloseYPoint=function(index){if(this.EnableNewIndex&&this.CorssCursorIndex){if(!this.StringFormatX||!this.StringFormatX.GetMinuteCloseYPoint)return null;var closeData=this.StringFormatX.GetMinuteCloseYPoint(this.CorssCursorIndex);if(!closeData)return null;this.Close=closeData.Price;return closeData.Y;}else{if(!IFrameSplitOperator.IsNumber(index))return null;index=parseInt(index.toFixed(0));//index=parseInt(index);
|
|
5704
5708
|
if(!this.StringFormatX.Data)return null;var data=this.StringFormatX.Data;if(!data.Data||data.Data.length<=0)return null;var dataIndex=data.DataOffset+index;if(dataIndex>=data.Data.length)dataIndex=data.Data.length-1;if(dataIndex<0)return null;var close=data.Data[dataIndex];if(!IFrameSplitOperator.IsNumber(index))return null;this.Close=close;var yPoint=this.Frame.GetYFromData(this.Close);return yPoint;}};this.GetDateTimeRange=function(index,option){if(!IFrameSplitOperator.IsNumber(index))return null;index=parseInt(index);var data=this.StringFormatX.Data;if(!data.Data||data.Data.length<=0)return null;var dataIndex=data.DataOffset+index;if(dataIndex>=data.Data.length||dataIndex<0)return null;if(!this.Frame||!this.Frame.SubFrame[0]||!this.Frame.SubFrame[0].Frame)return null;var frame=this.Frame.SubFrame[0].Frame;var dataWidth=frame.DataWidth;var distanceWidth=frame.DistanceWidth;var xPointCount=frame.XPointCount;var kItem=data.Data[dataIndex];if(!kItem)return null;var date=kItem.Date*1000000;var time=parseInt(kItem.Time/100)*100;var startTime=date+time;var endTime=date+time+59;var endIndex=dataIndex;for(var i=dataIndex;i<data.Data.length;++i){var item=data.Data[i];var dateTime=item.Date*1000000+item.Time;if(dateTime>endTime)break;if(i-data.DataOffset>=xPointCount)break;endIndex=i;}var startIndex=dataIndex;for(var i=dataIndex;i>=0&&i>=data.DataOffset;--i){var item=data.Data[i];var dateTime=item.Date*1000000+item.Time;if(dateTime<startTime)break;startIndex=i;}var range={StartIndex:startIndex,EndIndex:endIndex};range.XStart=this.Frame.GetXFromIndex(startIndex-data.DataOffset);range.XEnd=this.Frame.GetXFromIndex(endIndex-data.DataOffset);range.XStart-=(distanceWidth+dataWidth)/2;range.XEnd+=(distanceWidth+dataWidth)/2;return range;};this.FixMinuteLastTimeXPoint=function(index){if(!IFrameSplitOperator.IsNumber(index))return null;index=parseInt(index);if(!this.StringFormatX.Data)return null;var data=this.StringFormatX.Data;if(!data.Data||data.Data.length<=0)return null;var dataIndex=data.DataOffset+index;if(dataIndex<data.Data.length)return null;dataIndex=data.Data.length-1;dataIndex-=data.DataOffset;var xPoint=this.Frame.GetXFromIndex(dataIndex);return{X:xPoint,Index:dataIndex};};//返回 -1=不在客户区 1=在主区域 2=左边扩展 3=右边扩展
|
|
5705
5709
|
this.PtInClient=function(x,y){this.Canvas.beginPath();if(this.Frame.IsHScreen===true){var border=this.Frame.ChartBorder.GetHScreenBorder();this.Canvas.rect(border.Left,border.TopEx,border.Right-border.Left,border.BottomEx-border.TopEx);}else{var border=this.Frame.ChartBorder.GetBorder();this.Canvas.rect(border.LeftEx,border.Top,border.RightEx-border.LeftEx,border.Bottom-border.Top);}if(this.Canvas.isPointInPath(x,y))return 1;if(this.Frame.ChartBorder.LeftExtendWidth>10){this.Canvas.beginPath();if(this.Frame.IsHScreen===true){this.Canvas.rect(border.Left,border.Top,border.Right-border.Left,border.TopEx-border.Top);}else{this.Canvas.rect(border.Left,border.Top,border.LeftEx-border.Left,border.Bottom-border.Top);}if(this.Canvas.isPointInPath(x,y))return 2;}if(this.Frame.ChartBorder.RightExtendWidth>10){this.Canvas.beginPath();if(this.Frame.IsHScreen===true){this.Canvas.rect(border.Left,border.BottomEx,border.Right-border.Left,border.Bottom-border.BottomEx);}else{this.Canvas.rect(border.RightEx,border.Top,border.Right-border.RightEx,border.Bottom-border.Top);}if(this.Canvas.isPointInPath(x,y))return 3;}return-1;};this.GetFontHeight=function(font){return GetFontHeight(this.Canvas,font,"擎");};this.Draw=function(){this.Status=0;this.RightButton.Rect=null;this.BottomButton.Rect=null;this.LastValue=null;if(!this.LastPoint)return;this.Close=null;var x=this.LastPoint.X;var y=this.LastPoint.Y;var clientPos=this.PtInClient(x,y);this.PointY=null;this.PointY==null;this.ClientPos=clientPos;if(clientPos<=0)return;if(this.Frame.IsHScreen===true){this.HScreenDraw();return;}var border=this.Frame.ChartBorder.GetBorder();var left=border.Left;var right=border.Right;var top=border.TopTitle;var bottom=border.Bottom;var rightWidth=this.Frame.ChartBorder.Right;var chartRight=border.ChartWidth;if(this.IsOnlyDrawKLine)//手机端 十字只能画在K线上
|
|
5706
5710
|
{x=this.Frame.GetXFromIndex(this.CursorIndex);if(this.IsShowClose){var yPoint=this.GetCloseYPoint(this.CursorIndex);if(yPoint!=null)y=yPoint;}}else if(this.IsOnlyDrawMinute){var yPoint=this.GetMinuteCloseYPoint(this.CursorIndex);if(yPoint!=null)y=yPoint;}if(this.CallAcutionXOperator){this.CallAcutionXOperator.Value=x;this.CallAcutionXOperator.Point={X:x,Y:y};this.CallAcutionXOperator.ClientPos=clientPos;if(this.CallAcutionXOperator.Operator()){x=this.CallAcutionXOperator.X;}}if(this.IsFixXLastTime){var value=this.FixMinuteLastTimeXPoint(this.CursorIndex);if(value){x=value.X;this.CursorIndex=value.Index;}}this.PointY=[[left,y],[right,y]];this.PointX=[[x,top],[x,bottom]];//十字线
|
|
@@ -5713,70 +5717,41 @@ if(barWidth>2*pixel)this.Canvas.lineWidth=barWidth;}this.Canvas.beginPath();if(t
|
|
|
5713
5717
|
//this.StringFormatX.Value=xValue;
|
|
5714
5718
|
this.StringFormatX.Value=this.CursorIndex;this.StringFormatX.Point={X:x,Y:y};this.StringFormatX.ClientPos=clientPos;this.StringFormatY.Value=yValue;this.StringFormatY.RValue=yValueExtend.RightYValue;//右侧子坐标
|
|
5715
5719
|
this.StringFormatY.FrameID=yValueExtend.FrameID;this.StringFormatY.Point={X:x,Y:y};this.StringFormatY.ClientPos=clientPos;this.Canvas.font=this.Font;var textHeight=this.GetFontHeight();if(textHeight>this.TextHeight)this.TextHeight=textHeight;//Y轴
|
|
5716
|
-
if((this.ShowTextMode.Left==1&&this.Frame.ChartBorder.Left>=30||this.ShowTextMode.Left==2||this.ShowTextMode.Right==1&&this.Frame.ChartBorder.Right>=30||this.ShowTextMode.Right==2)&&this.StringFormatY.Operator()){
|
|
5720
|
+
if((this.ShowTextMode.Left==1&&this.Frame.ChartBorder.Left>=30||this.ShowTextMode.Left==2||this.ShowTextMode.Right==1&&this.Frame.ChartBorder.Right>=30||this.ShowTextMode.Right==2)&&this.StringFormatY.Operator()){//计算右侧文本输出顶部位置
|
|
5721
|
+
var _Temp_CalculateRightTextBGTop=function _Temp_CalculateRightTextBGTop(rtBG,complexText,defaultTextHeight){if(complexText.ShowType==1){var yValue=defaultTextHeight/2;if(IFrameSplitOperator.IsNonEmptyArray(textSize.Text)&&textSize.Text[0]){var itemSize=textSize.Text[0];if(IFrameSplitOperator.IsNumber(itemSize.Height))yValue=itemSize.Height/2;}rtBG.Top=rtBG.YCenter-yValue;rtBG.Bottom=rtBG.Top+rtBG.Height;}else{rtBG.Top=rtBG.YCenter-rtBG.Height/2;rtBG.Bottom=rtBG.Top+rtBG.Height;}};var text=this.StringFormatY.Text;this.Canvas.font=this.Font;var textWidth=this.Canvas.measureText(text).width;//前后各空2个像素
|
|
5717
5722
|
var textSize={Width:textWidth+4,Height:this.TextHeight,Text:[]};var buttonData={Y:y,YValue:yValue,FrameID:yValueExtend.FrameID};var margin=this.LeftConfig.Margin;var textOffset=this.LeftConfig.TextOffset;var rtBG=null;if(this.Frame.ChartBorder.Left>=30&&this.ShowTextMode.Left==1)//左边
|
|
5718
5723
|
{var rtBG={Right:left,Width:textWidth+margin.Left+margin.Right,YCenter:y,Height:textHeight+margin.Top+margin.Bottom};rtBG.Left=rtBG.Right-rtBG.Width;rtBG.Top=rtBG.YCenter-rtBG.Height/2;rtBG.Bottom=rtBG.Top+rtBG.Height;if(rtBG.Left<0){rtBG.Left=0;rtBG.Right=rtBG.Left+rtBG.Width;}}else if(this.ShowTextMode.Left==2)//在框架内显示
|
|
5719
5724
|
{var rtBG={Left:left,Width:textWidth+margin.Left+margin.Right,YCenter:y,Height:textHeight+margin.Top+margin.Bottom};rtBG.Right=rtBG.Left+rtBG.Width;rtBG.Top=rtBG.YCenter-rtBG.Height/2;rtBG.Bottom=rtBG.Top+rtBG.Height;}if(rtBG){this.DrawTextBGRect(rtBG.Left,rtBG.Top,rtBG.Width,rtBG.Height);this.Canvas.textAlign="left";this.Canvas.textBaseline="bottom";this.Canvas.fillStyle=this.TextColor;this.Canvas.fillText(text,rtBG.Left+textOffset.X,rtBG.Bottom+textOffset.Y);}var complexText={ShowType:0,//0=单行(默认) 1=多行
|
|
5720
|
-
Font:this.Font,Color:this.TextColor,Text:[{Text:text,Margin:this.
|
|
5725
|
+
Font:this.Font,Color:this.TextColor,Text:[{Text:text,Margin:this.RightConfig.Margin,TextOffset:this.RightConfig.TextOffset}]};var yTop=y-this.TextHeight/2;if(this.StringFormatY.PercentageText){if(this.TextFormat.Right==0){text=this.StringFormatY.PercentageText+'%';complexText.Text[0].Text=text;}}if(this.StringFormatY.RText){text=this.StringFormatY.RText;complexText.Text[0].Text=text;}if(this.StringFormatY.RComplexText&&IFrameSplitOperator.IsNonEmptyArray(this.StringFormatY.RComplexText.Text)){complexText=this.StringFormatY.RComplexText;if(!complexText.Font)complexText.Font=this.Font;if(!complexText.Color)complexText.Color=this.TextColor;}this.CalculateComplexTextSize(complexText,textSize);if(this.Frame.ChartBorder.Right>=30&&this.ShowTextMode.Right==1){var isOverlayIndex=false;//是否有叠加子坐标
|
|
5721
5726
|
var overlayIndexInterval=null;//子坐标间距
|
|
5722
5727
|
if(yValueExtend.FrameID>=0){var frame=this.Frame.SubFrame[yValueExtend.FrameID];isOverlayIndex=frame.OverlayIndex.length>0;overlayIndexInterval=null;if(isOverlayIndex){for(var i=0;i<=frame.OverlayIndex.length;++i){var item=frame.OverlayIndex[i];if(!item||!item.Frame)continue;if(item.Frame.IsShow===false)continue;if(!item.Frame.GetXHorizontal)continue;var overlayLeft=item.Frame.GetXHorizontal();overlayIndexInterval=overlayLeft-right;break;}}}//叠加坐标
|
|
5723
5728
|
if(isOverlayIndex&&textSize.Width>overlayIndexInterval&&overlayIndexInterval>0)//大于子坐标宽度
|
|
5724
|
-
{var
|
|
5725
|
-
{var
|
|
5726
|
-
if (this.StringFormatY.RExtendText && this.StringFormatY.RExtendText.length>0)
|
|
5727
|
-
{
|
|
5728
|
-
var yOffset=0;
|
|
5729
|
-
for(var i in this.StringFormatY.RExtendText)
|
|
5730
|
-
{
|
|
5731
|
-
var item=this.StringFormatY.RExtendText[i];
|
|
5732
|
-
var rText='--.--'
|
|
5733
|
-
if (item.YText) rText=item.YText;
|
|
5734
|
-
else if (IFrameSplitOperator.IsNumber(item.Y)) rText=item.Y.toFixed(0);
|
|
5735
|
-
var rTextWidth=this.Canvas.measureText(rText).width+4; //前后各空2个像素
|
|
5736
|
-
|
|
5737
|
-
if (rightWidth<rTextWidth)
|
|
5738
|
-
{
|
|
5739
|
-
this.DrawTextBGRect(chartRight-2-rTextWidth,y+yOffset+this.TextHeight/2,rTextWidth,this.TextHeight);
|
|
5740
|
-
this.Canvas.textAlign="right";
|
|
5741
|
-
this.Canvas.textBaseline="middle";
|
|
5742
|
-
this.Canvas.fillStyle=item.TextColor;
|
|
5743
|
-
this.Canvas.fillText(rText,chartRight-4,y+yOffset+this.TextHeight,rTextWidth);
|
|
5744
|
-
}
|
|
5745
|
-
else
|
|
5746
|
-
{
|
|
5747
|
-
this.DrawTextBGRect(right+2,y+yOffset+this.TextHeight/2,rTextWidth,this.TextHeight);
|
|
5748
|
-
this.Canvas.textAlign="left";
|
|
5749
|
-
this.Canvas.textBaseline="middle";
|
|
5750
|
-
this.Canvas.fillStyle=item.TextColor;
|
|
5751
|
-
this.Canvas.fillText(rText,right+4,y+yOffset+this.TextHeight,rTextWidth);
|
|
5752
|
-
}
|
|
5753
|
-
|
|
5754
|
-
yOffset+=this.TextHeight;
|
|
5755
|
-
}
|
|
5756
|
-
}
|
|
5757
|
-
*/}else if(this.ShowTextMode.Right==2){this.Canvas.fillStyle=this.TextBGColor;var showLeft=right-textSize.Width;this.DrawTextBGRect(showLeft,yTop,textSize.Width,textSize.Height);this.DrawComplexTextV2(showLeft,yTop,complexText,textSize);if(this.RightButton.Enable)this.DrawRightButton(yTop,showLeft,this.TextHeight,this.TextHeight,buttonData);}}//X轴 Bottom==8 自定义
|
|
5729
|
+
{var rtBG={Right:right+overlayIndexInterval,Width:textSize.Width,YCenter:y,Height:textSize.Height};rtBG.Left=rtBG.Right-rtBG.Width;_Temp_CalculateRightTextBGTop(rtBG,complexText,this.TextHeight);if(rtBG.Right>chartRight){rtBG.Right=chartRight;rtBG.Left=rtBG.Right-rtBG.Width;}var drawRight=right+overlayIndexInterval;if(drawRight>chartRight)drawRight=chartRight;this.DrawTextBGRect(rtBG.Left,rtBG.Top,rtBG.Width,rtBG.Height);this.DrawComplexRightText(rtBG,complexText,textSize);if(this.RightButton.Enable)this.DrawRightButtonV2(rtBG,complexText,textSize,buttonData);}else{var rtBG={Left:right+1,Width:textSize.Width,YCenter:y,Height:textSize.Height};rtBG.Right=rtBG.Left+rtBG.Width;_Temp_CalculateRightTextBGTop(rtBG,complexText,this.TextHeight);if(rtBG.Right>chartRight){rtBG.Right=chartRight;rtBG.Left=rtBG.Right-rtBG.Width;}this.DrawTextBGRect(rtBG.Left,rtBG.Top,rtBG.Width,rtBG.Height);this.DrawComplexRightText(rtBG,complexText,textSize);if(this.RightButton.Enable)this.DrawRightButtonV2(rtBG,complexText,textSize,buttonData);}}else if(this.ShowTextMode.Right==2)//框架内侧显示
|
|
5730
|
+
{var rtBG={Right:right,Width:textSize.Width,YCenter:y,Height:textSize.Height};rtBG.Left=rtBG.Right-rtBG.Width;_Temp_CalculateRightTextBGTop(rtBG,complexText,this.TextHeight);this.Canvas.fillStyle=this.TextBGColor;this.DrawTextBGRect(rtBG.Left,rtBG.Top,rtBG.Width,rtBG.Height);this.DrawComplexRightText(rtBG,complexText,textSize);if(this.RightButton.Enable)this.DrawRightButtonV2(rtBG,complexText,textSize,buttonData);}}//X轴 Bottom==8 自定义
|
|
5758
5731
|
if((this.ShowTextMode.Bottom==1||this.ShowTextMode.Bottom==2||this.ShowTextMode.Bottom==8)&&this.StringFormatX.Operator()){var text=this.StringFormatX.Text;this.Canvas.font=this.Font;this.Canvas.fillStyle=this.TextBGColor;var textWidth=this.Canvas.measureText(text).width;//前后各空2个像素
|
|
5759
5732
|
var margin=this.BottomConfig.Margin;var textOffset=this.BottomConfig.TextOffset;var rtBG={Top:bottom,Height:margin.Top+margin.Bottom+textHeight,XCenter:x,Width:textWidth+margin.Left+margin.Right};rtBG.Bottom=rtBG.Top+rtBG.Height;rtBG.Left=rtBG.XCenter-rtBG.Width/2;rtBG.Right=rtBG.Left+rtBG.Width;if(rtBG.Left<=0){rtBG.Left=0;rtBG.Right=rtBG.Left+rtBG.Width;}else if(rtBG.Right>=right){rtBG.Right=right;rtBG.Left=rtBG.Right-rtBG.Width;}var bShowText=true;if(this.ShowTextMode.Bottom==2){rtBG.Bottom=bottom;rtBG.Top=rtBG.Bottom-rtBG.Height;}else if(this.ShowTextMode.Bottom==8){var event=this.GetEventCallback(JSCHART_EVENT_ID.ON_CUSTOM_CORSSCURSOR_POSITION);if(event&&event.Callback){var sendData={RectText:rtBG,IsShowText:bShowText,X:x,Y:y};event.Callback(event,sendData,this);bShowText=sendData.IsShowText;}}//JSConsole.Chart.Log('[ChartCorssCursor::Draw] ',yCenter);
|
|
5760
5733
|
if(bShowText){this.DrawTextBGRect(rtBG.Left,rtBG.Top,rtBG.Width,rtBG.Height);this.Canvas.textAlign="left";this.Canvas.textBaseline="bottom";this.Canvas.fillStyle=this.TextColor;this.Canvas.fillText(text,rtBG.Left+textOffset.X,rtBG.Bottom+textOffset.Y,textWidth);var buttonData={X:x,Y:y,XValue:xValue,FrameID:yValueExtend.FrameID};if(this.StringFormatX.KItem)buttonData.KItem=this.StringFormatX.KItem;this.BottomButton.Rect=rtBG;this.BottomButton.Data=buttonData;}}//子坐标Y轴
|
|
5761
5734
|
if(yValueExtend.FrameID>=0){var frame=this.Frame.SubFrame[yValueExtend.FrameID];var overlayLeft=right;this.Canvas.font=this.Font;for(var i=0;i<frame.OverlayIndex.length;++i){var item=frame.OverlayIndex[i];if(item.Frame.IsShow===false)continue;if(!item.Frame.GetXHorizontal)continue;overlayLeft=item.Frame.GetXHorizontal();//if (overlayLeft+30>chartRight) break;
|
|
5762
|
-
var yValue=item.Frame.GetYData(y);var text=IFrameSplitOperator.FormatValueString(yValue,2);var textWidth=this.Canvas.measureText(text).width
|
|
5763
|
-
|
|
5735
|
+
var yValue=item.Frame.GetYData(y);var text=IFrameSplitOperator.FormatValueString(yValue,2);var textWidth=this.Canvas.measureText(text).width;//前后各空2个像素
|
|
5736
|
+
var margin=this.RightOverlayConfig.Margin;var textOffset=this.RightOverlayConfig.TextOffset;var rtBG={Left:overlayLeft+1,Width:textWidth+margin.Left+margin.Right,YCenter:y,Height:textHeight+margin.Top+margin.Bottom};rtBG.Right=rtBG.Left-rtBG.Width;rtBG.Top=rtBG.YCenter-rtBG.Height/2;rtBG.Bottom=rtBG.Top+rtBG.Height;this.DrawTextBGRect(rtBG.Left,rtBG.Top,rtBG.Width,rtBG.Height);/*
|
|
5764
5737
|
for(var j=2;j>=0;--j)
|
|
5765
5738
|
{
|
|
5766
5739
|
var text=IFrameSplitOperator.FormatValueString(yValue,j);
|
|
5767
5740
|
var textWidth=this.Canvas.measureText(text).width+4; //前后各空2个像素
|
|
5768
5741
|
if (textWidth<frame.Interval) break;
|
|
5769
5742
|
}
|
|
5770
|
-
*/this.Canvas.
|
|
5771
|
-
{var xLeft=
|
|
5772
|
-
for(var i=0;i<complexText.Text.length;++i){var item=complexText.Text[i];var itemSize=size.Text[i];if(item.Font)this.Canvas.font=item.Font;else this.Canvas.font=complexText.Font;if(item.Color)this.Canvas.fillStyle=item.Color;else this.Canvas.fillStyle=complexText.Color;var y=
|
|
5773
|
-
{var xText=
|
|
5743
|
+
*/this.Canvas.textAlign="left";this.Canvas.textBaseline="bottom";this.Canvas.fillStyle=this.TextColor;this.Canvas.fillText(text,rtBG.Left+textOffset.X,rtBG.Bottom+textOffset.Y);}}this.Status=1;};this.DrawComplexRightText=function(rtBG,complexText,size){this.Canvas.textAlign="left";this.Canvas.textBaseline="bottom";var showType=0;if(complexText.ShowType==1)showType=complexText.ShowType;if(showType==1)//多行
|
|
5744
|
+
{var xLeft=rtBG.Left;var yTop=rtBG.Top;//顶
|
|
5745
|
+
for(var i=0;i<complexText.Text.length;++i){var item=complexText.Text[i];var itemSize=size.Text[i];if(item.Font)this.Canvas.font=item.Font;else this.Canvas.font=complexText.Font;if(item.Color)this.Canvas.fillStyle=item.Color;else this.Canvas.fillStyle=complexText.Color;var y=yTop+itemSize.Height;var x=xLeft;if(item.TextOffset){var textOffset=item.TextOffset;if(IFrameSplitOperator.IsNumber(textOffset.X))x+=textOffset.X;if(IFrameSplitOperator.IsNumber(textOffset.Y))y+=textOffset.Y;}this.Canvas.fillText(item.Text,x,y,itemSize.Width);yTop+=itemSize.Height;}}else//水平 单行
|
|
5746
|
+
{var xText=rtBG.Left;var yBottom=rtBG.Bottom;for(var i=0;i<complexText.Text.length;++i){var item=complexText.Text[i];var itemSize=size.Text[i];if(item.Font)this.Canvas.font=item.Font;else this.Canvas.font=complexText.Font;if(item.Color)this.Canvas.fillStyle=item.Color;else this.Canvas.fillStyle=complexText.Color;var x=xText;var y=yBottom;if(item.TextOffset){var textOffset=item.TextOffset;if(IFrameSplitOperator.IsNumber(textOffset.X))x+=textOffset.X;if(IFrameSplitOperator.IsNumber(textOffset.Y))y+=textOffset.Y;}this.Canvas.fillText(item.Text,x,y,itemSize.Width);xText+=itemSize.Width;}}};this.CalculateComplexTextSize=function(complexText,size){if(!complexText||!IFrameSplitOperator.IsNonEmptyArray(complexText.Text))return;var showType=0;if(complexText.ShowType==1)showType=complexText.ShowType;if(showType==1)//多行
|
|
5774
5747
|
{var textWidth=0,textHeight=0;for(var i=0;i<complexText.Text.length;++i){var item=complexText.Text[i];if(item.Font)this.Canvas.font=item.Font;else this.Canvas.font=complexText.Font;var itemWidth=this.Canvas.measureText(item.Text).width;//前后各空2个像素
|
|
5775
|
-
var itemHeight=this.
|
|
5748
|
+
var itemHeight=this.GetFontHeight();if(item.Margin){var margin=item.Margin;if(IFrameSplitOperator.IsNumber(margin.Left))itemWidth+=margin.Left;if(IFrameSplitOperator.IsNumber(margin.Right))itemWidth+=margin.Right;if(IFrameSplitOperator.IsNumber(margin.Top))itemHeight+=margin.Top;if(IFrameSplitOperator.IsNumber(margin.Bottom))itemHeight+=margin.Bottom;}size.Text[i]={Width:itemWidth,Height:itemHeight};//保存所有文字的大小信息
|
|
5776
5749
|
if(textWidth<itemWidth)textWidth=itemWidth;textHeight+=itemHeight;}size.Width=textWidth;size.Height=textHeight;}else//水平 单行
|
|
5777
|
-
{var textWidth=0,textHeight=
|
|
5750
|
+
{var textWidth=0,textHeight=this.GetFontHeight();for(var i=0;i<complexText.Text.length;++i){var item=complexText.Text[i];if(item.Font)this.Canvas.font=item.Font;else this.Canvas.font=complexText.Font;var itemWidth=this.Canvas.measureText(item.Text).width;//前后各空2个像素
|
|
5778
5751
|
var itemHeight=this.Canvas.measureText("擎").width;if(item.Margin){var margin=item.Margin;if(IFrameSplitOperator.IsNumber(margin.Left))itemWidth+=margin.Left;if(IFrameSplitOperator.IsNumber(margin.Right))itemWidth+=margin.Right;if(IFrameSplitOperator.IsNumber(margin.Top))itemHeight+=margin.Top;if(IFrameSplitOperator.IsNumber(margin.Bottom))itemHeight+=margin.Bottom;}size.Text[i]={Width:itemWidth,Height:itemHeight};//保存所有文字的大小信息
|
|
5779
|
-
textWidth+=itemWidth;if(textHeight<itemHeight)textHeight=itemHeight;}size.Width=textWidth;size.Height=textHeight;}};this.
|
|
5752
|
+
textWidth+=itemWidth;if(textHeight<itemHeight)textHeight=itemHeight;}size.Width=textWidth;size.Height=textHeight;}};this.DrawRightButtonV2=function(rtTextBG,complexText,textSize,data){this.Canvas.fillStyle=this.RightButton.BGColor;var drawHeight=rtTextBG.Height;var drawWidth=rtTextBG.Height;if(complexText.ShowType==1)//多行 取第1行高度
|
|
5753
|
+
{var itemSize=textSize.Text[0];drawHeight=itemSize.Height;drawWidth=itemSize.Height;}var rtButton={Left:rtTextBG.Left-drawHeight,Top:rtTextBG.Top,Width:drawWidth,Height:drawHeight};rtButton.Right=rtButton.Left+rtButton.Width;rtButton.Bottom=rtButton.Top+rtButton.Height;this.RightButton.Rect=rtButton;this.RightButton.Data=data;this.Canvas.fillRect(ToFixedPoint(rtButton.Left+1),ToFixedPoint(rtButton.Top),ToFixedRect(rtButton.Width),ToFixedRect(rtButton.Height));var pixelRatio=GetDevicePixelRatio();var spaceWidth=3;var yCenter=rtButton.Top+spaceWidth+(rtButton.Height-spaceWidth*2)/2;var xCenter=rtButton.Left+spaceWidth+(rtButton.Width-spaceWidth*2)/2;if(this.RightButton.Icon){var icon=this.RightButton.Icon;this.Canvas.font=icon.Size*pixelRatio+'px '+icon.Family;this.Canvas.textAlign="center";this.Canvas.textBaseline="middle";this.Canvas.fillStyle=icon.Color;this.Canvas.fillText('\uE6A3',xCenter,yCenter);}else{//画加号
|
|
5754
|
+
this.Canvas.strokeStyle=this.RightButton.PenColor;var x=rtButtom.Left+spaceWidth;var y=rtButtom.Top+spaceWidth;this.Canvas.save();this.Canvas.linewidth=1*pixelRatio;this.Canvas.beginPath();this.Canvas.moveTo(ToFixedPoint(x),ToFixedPoint(yCenter));this.Canvas.lineTo(ToFixedPoint(x+rtButton.Width-spaceWidth*2),ToFixedPoint(yCenter));this.Canvas.moveTo(ToFixedPoint(xCenter),ToFixedPoint(y));this.Canvas.lineTo(ToFixedPoint(xCenter),ToFixedPoint(y+rtButton.Height-spaceWidth*2));this.Canvas.stroke();this.Canvas.restore();}};this.DrawRightButton=function(drawTop,drawRight,drawWidth,drawHeight,data){this.Canvas.fillStyle=this.RightButton.BGColor;var rtButton={Left:drawRight-drawWidth,Top:drawTop,Width:drawWidth,Height:drawHeight};rtButton.Right=rtButton.Left+rtButton.Width;rtButton.Bottom=rtButton.Top+rtButton.Height;this.RightButton.Rect=rtButton;this.RightButton.Data=data;this.Canvas.fillRect(ToFixedPoint(rtButton.Left+1),ToFixedPoint(rtButton.Top),ToFixedRect(rtButton.Width),ToFixedRect(rtButton.Height));var pixelRatio=GetDevicePixelRatio();var spaceWidth=3;var yCenter=rtButton.Top+spaceWidth+(rtButton.Height-spaceWidth*2)/2;var xCenter=rtButton.Left+spaceWidth+(rtButton.Width-spaceWidth*2)/2;if(this.RightButton.Icon){var icon=this.RightButton.Icon;this.Canvas.font=icon.Size*pixelRatio+'px '+icon.Family;this.Canvas.textAlign="center";this.Canvas.textBaseline="middle";this.Canvas.fillStyle=icon.Color;this.Canvas.fillText('\uE6A3',xCenter,yCenter);}else{//画加号
|
|
5780
5755
|
this.Canvas.strokeStyle=this.RightButton.PenColor;var x=rtButtom.Left+spaceWidth;var y=rtButtom.Top+spaceWidth;this.Canvas.save();this.Canvas.linewidth=1*pixelRatio;this.Canvas.beginPath();this.Canvas.moveTo(ToFixedPoint(x),ToFixedPoint(yCenter));this.Canvas.lineTo(ToFixedPoint(x+rtButton.Width-spaceWidth*2),ToFixedPoint(yCenter));this.Canvas.moveTo(ToFixedPoint(xCenter),ToFixedPoint(y));this.Canvas.lineTo(ToFixedPoint(xCenter),ToFixedPoint(y+rtButton.Height-spaceWidth*2));this.Canvas.stroke();this.Canvas.restore();}};this.PtInButton=function(x,y){var item=this.PtInRightButton(x,y);if(item)return item;item=this.PtInButtomButton(x,y);if(item)return item;return null;};this.PtInRightButton=function(x,y){if(!this.RightButton.Enable)return null;if(!this.RightButton.Rect)return null;var rect=this.RightButton.Rect;if(x>=rect.Left&&x<=rect.Right&&y>=rect.Top&&y<=rect.Bottom){return{Data:this.RightButton.Data,Rect:rect,Type:1};//Type:1=右侧 2=底部
|
|
5781
5756
|
}return null;};this.PtInButtomButton=function(x,y){if(!this.BottomButton.Enable)return null;if(!this.BottomButton.Rect)return null;var rect=this.BottomButton.Rect;if(x>=rect.Left&&x<=rect.Right&&y>=rect.Top&&y<=rect.Bottom){return{Data:this.BottomButton.Data,Rect:rect,Type:2};//Type:1=右侧 2=底部
|
|
5782
5757
|
}return null;};this.DrawTextBGRect=function(x,y,height,width){this.Canvas.fillStyle=this.TextBGColor;this.Canvas.fillRect(ToFixedPoint(x),ToFixedPoint(y),ToFixedRect(height),ToFixedRect(width));if(this.BorderColor){this.Canvas.strokeStyle=this.BorderColor;this.Canvas.strokeRect(ToFixedPoint(x),ToFixedPoint(y),ToFixedRect(height),ToFixedRect(width));}};this.HScreenDraw=function(){var x=this.LastPoint.X;var y=this.LastPoint.Y;if(this.IsOnlyDrawKLine)//手机端 十字只能画在K线上
|
|
@@ -6996,7 +6971,8 @@ this.CorssCursorTextFont=14*GetDevicePixelRatio()+"px 微软雅黑";this.CorssCu
|
|
|
6996
6971
|
this.CorssCursorVPenColor="rgb(130,130,130)";//十字光标线段颜色(垂直)
|
|
6997
6972
|
this.CorssCursorXRangeBGColor="rgba(100,149,237,0.3)";//十字光标X轴访问背景色
|
|
6998
6973
|
this.CorssCursorLineDash=[3*GetDevicePixelRatio(),2*GetDevicePixelRatio()];//十字光标虚线
|
|
6999
|
-
this.CorssCursor={RightButton:{BGColor:'rgb(43,54,69)',PenColor:'rgb(255,255,255)',Icon:{Text:'\uE6A3',Color:'rgb(255,255,255)',Family:"iconfont",Size:
|
|
6974
|
+
this.CorssCursor={RightButton:{BGColor:'rgb(43,54,69)',PenColor:'rgb(255,255,255)',Icon:{Text:'\uE6A3',Color:'rgb(255,255,255)',Family:"iconfont",Size:14}},BottomText:{Margin:{Left:4,Right:4,Top:0,Bottom:0},TextOffset:{X:4,Y:-1}},LeftText:{Margin:{Left:4,Right:4,Top:0,Bottom:0},TextOffset:{X:4,Y:-1}},RightText:{Margin:{Left:4,Right:4,Top:0,Bottom:0},TextOffset:{X:4,Y:-1}},RightOverlayText:{Margin:{Left:2,Right:2,Top:0,Bottom:0},TextOffset:{X:2,Y:-1}},//右侧叠加坐标
|
|
6975
|
+
CorssPoint:{Center:{Radius:5*GetDevicePixelRatio(),Color:"rgb(50,171,205)"},Border:{Color:'rgb(255,255,255)',Width:1*GetDevicePixelRatio()}}};//指标锁
|
|
7000
6976
|
this.IndexLock={BGColor:"rgb(220, 220, 220)",TextColor:"rgb(210, 34, 34)",Font:14*GetDevicePixelRatio()+'px \u5FAE\u8F6F\u96C5\u9ED1',Title:'🔒开通权限'};this.Domain="http://127.0.0.1:8080";//API域名
|
|
7001
6977
|
this.CacheDomain="http://127.0.0.1:8087";//缓存域名
|
|
7002
6978
|
this.PyIndexDomain='http://127.0.0.1:8088';//py指标计算域名
|
|
@@ -12558,7 +12534,7 @@ UnchagneBarColor:"rgb(190,190,190)",//平盘
|
|
|
12558
12534
|
BGAlpha:0.6,EmptyBGColor:"rgb(0,0,0)"},CorssCursorBGColor:"rgb(43,54,69)",//十字光标背景
|
|
12559
12535
|
CorssCursorTextColor:"rgb(255,255,255)",CorssCursorTextFont:12*GetDevicePixelRatio()+"px 微软雅黑",CorssCursorHPenColor:"rgb(130,130,130)",//十字光标线段颜色
|
|
12560
12536
|
CorssCursorVPenColor:"rgb(130,130,130)",//十字光标线段颜色
|
|
12561
|
-
CorssCursor:{RightButton:{BGColor:'rgb(43,54,69)',PenColor:'rgb(255,255,255)',Icon:{Text:'\uE6A3',Color:'rgb(255,255,255)',Family:"iconfont",Size:
|
|
12537
|
+
CorssCursor:{RightButton:{BGColor:'rgb(43,54,69)',PenColor:'rgb(255,255,255)',Icon:{Text:'\uE6A3',Color:'rgb(255,255,255)',Family:"iconfont",Size:12}},CorssPoint:{Center:{Color:"rgb(50,171,205)"},Border:{Color:'rgba(0,0,0,0.8)',Width:1*GetDevicePixelRatio()}}},//订单流配置
|
|
12562
12538
|
OrderFlow:{UpColor:{BG:'rgb(223,191,180)',Border:"rgb(196,84,86)"},//阳线
|
|
12563
12539
|
DownColor:{BG:"rgb(176,212,184)",Border:'rgb(66,94,74)'},//阴线
|
|
12564
12540
|
UnchagneColor:{BG:"rgb(216,221,177)",Border:"rgb(209,172,129)"},//平盘
|
|
@@ -14792,7 +14768,7 @@ hisData.Symbol=message.symbol;}var stockObj={HQDataType:HQ_DATA_TYPE.KLINE_ID,St
|
|
|
14792
14768
|
this.ExecuteScript(item,data);}this.Status=0;}};this.OnExecuteFinish=function(data,indexInfo,jsExectute,jobInfo){var message={Data:data,IndexInfo:indexInfo,ID:JSCHART_WORKER_MESSAGE_ID.FINISH_EXECUTE_SCRIPT,JobInfo:jobInfo};postMessage(message);};this.OnExecuteError=function(error,indexInfo,jobData){var message={IndexInfo:indexInfo,ID:JSCHART_WORKER_MESSAGE_ID.ERROR_EXECUTE_SCRIPT,Error:error};postMessage(message);};}/********************************************************************************
|
|
14793
14769
|
* 版本信息输出
|
|
14794
14770
|
*
|
|
14795
|
-
*/var HQCHART_VERSION="1.1.
|
|
14771
|
+
*/var HQCHART_VERSION="1.1.14730";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: '+HQCHART_VERSION+' \n* License: Apache License 2.0 \n* Source: https://github.com/jones2000/HQChart\n*\n************************************************************************************************************************************************************************** \n ';console.log(logo);}PrintHQChartVersion();//把给外界调用的方法暴露出来
|
|
14796
14772
|
exports.default=(_jsChartInit$jsChartS={jsChartInit:JSChart.Init,jsChartStyle:JSChart.SetStyle,// IsIndexSymbol:IsIndexSymbol,
|
|
14797
14773
|
// BaseIndex:BaseIndex,
|
|
14798
14774
|
// ChartLine:ChartLine,
|