hqchart 1.1.12725 → 1.1.12729
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
CHANGED
|
@@ -2217,12 +2217,16 @@ this.LeftButtonWidth=0;//左侧按钮的宽度
|
|
|
2217
2217
|
this.IsMinSize=false;//窗口是否最小化
|
|
2218
2218
|
this.LogoTextColor=g_JSChartResource.FrameLogo.TextColor;this.LogoTextFont=g_JSChartResource.FrameLogo.Font;this.LogoBGColor=g_JSChartResource.FrameLogo.BGColor;this.GlobalOption;//this.IsDrawLeftBorder;
|
|
2219
2219
|
this.IsDrawRightBorder=false;//是否绘制右侧刻度空白的边框
|
|
2220
|
+
this.IsDrawLeftBorder=false;//是否绘制右侧刻度空白的边框
|
|
2220
2221
|
this.PtInButtons=function(x,y)//坐标是否在按钮上
|
|
2221
2222
|
{for(var i=0;i<this.Buttons.length;++i){var item=this.Buttons[i];if(!item.Rect)continue;var rect=item.Rect;this.Canvas.beginPath();this.Canvas.rect(rect.Left,rect.Top,rect.Width,rect.Height);if(this.Canvas.isPointInPath(x,y)){return{ID:item.ID,Rect:rect};}}return null;};this.GetBorder=function(){if(this.IsHScreen)return this.ChartBorder.GetHScreenBorder();else return this.ChartBorder.GetBorder();};this.Draw=function(){this.Buttons=[];this.DrawClientBG();this.DrawFrame();this.DrawBorder();this.SizeChange=false;this.XYSplit=false;this.XSplit=false;};this.DrawFrame=function(){};this.DrawClientBG=function(){if(!this.ClientBGColor)return;var border=this.IsHScreen==true?this.ChartBorder.GetHScreenBorder():this.ChartBorder.GetBorder();var left=ToFixedPoint(border.Left);var top=ToFixedPoint(border.Top);//var top=ToFixedPoint(border.TopEx);
|
|
2222
2223
|
var right=ToFixedPoint(border.Right);var bottom=ToFixedPoint(border.Bottom);var width=right-left;var height=bottom-top;this.Canvas.fillStyle=this.ClientBGColor;this.Canvas.fillRect(left,top,width,height);};this.ClearCoordinateText=function(option){if(IFrameSplitOperator.IsNonEmptyArray(this.HorizontalInfo)){for(var i=0;i<this.HorizontalInfo.length;++i){var item=this.HorizontalInfo[i];if(item&&item.Message&&Array.isArray(item.Message))item.Message[0]=item.Message[1]=null;}}if(IFrameSplitOperator.IsNonEmptyArray(this.VerticalInfo)){for(var i=0;i<this.VerticalInfo.length;++i){var item=this.VerticalInfo[i];if(item&&item.Message&&Array.isArray(item.Message))item.Message[0]=item.Message[1]=null;}}};//画边框
|
|
2223
2224
|
this.DrawBorder=function(){if(!this.IsShowBorder)return;if(this.IsMinSize)return;var border=this.IsHScreen==true?this.ChartBorder.GetHScreenBorder():this.ChartBorder.GetBorder();var left=ToFixedPoint(border.Left);var top=ToFixedPoint(border.Top);//var top=ToFixedPoint(border.TopEx);
|
|
2224
2225
|
var right=ToFixedPoint(border.Right);var bottom=ToFixedPoint(border.Bottom);var width=right-left;var height=bottom-top;//JSConsole.Chart.Log(`[IChartFramePainting.DrawBorder] left=${left} `);
|
|
2225
|
-
if(this.BorderLine==null){if(this.IsDrawRightBorder){
|
|
2226
|
+
if(this.BorderLine==null){if(this.IsDrawRightBorder||this.IsDrawLeftBorder){this.Canvas.strokeStyle=this.PenBorder;if(this.IsDrawRightBorder&&this.IsDrawLeftBorder){var xRight=ToFixedPoint(border.ChartWidth);var xLeft=ToFixedPoint(0);this.Canvas.strokeRect(xLeft,top,xRight-xLeft-1,height);//少一个像素让边框显示出来
|
|
2227
|
+
}else if(this.IsDrawRightBorder){var xRight=ToFixedPoint(border.ChartWidth);this.Canvas.strokeRect(left,top,xRight-left-1,height);//少一个像素让边框显示出来
|
|
2228
|
+
}else if(this.IsDrawLeftBorder){var xLeft=ToFixedPoint(0);this.Canvas.strokeRect(xLeft,top,right-xLeft,height);//少一个像素让边框显示出来
|
|
2229
|
+
}if(this.IsDrawRightBorder){this.Canvas.beginPath();this.Canvas.moveTo(right,top);this.Canvas.lineTo(right,bottom);this.Canvas.stroke();}if(this.IsDrawLeftBorder){this.Canvas.beginPath();this.Canvas.moveTo(left,top);this.Canvas.lineTo(left,bottom);this.Canvas.stroke();}}else{this.Canvas.strokeStyle=this.PenBorder;this.Canvas.strokeRect(left,top,width,height);}}else if(IFrameSplitOperator.IsPlusNumber(this.BorderLine))//单独绘制每个边框
|
|
2226
2230
|
{this.Canvas.strokeStyle=this.PenBorder;this.Canvas.beginPath();if((this.BorderLine&1)>0)//上
|
|
2227
2231
|
{this.Canvas.moveTo(left,top);this.Canvas.lineTo(right,top);}if((this.BorderLine&2)>0)//下
|
|
2228
2232
|
{this.Canvas.moveTo(left,bottom);this.Canvas.lineTo(right,bottom);}if((this.BorderLine&4)>0)//左
|
|
@@ -2286,8 +2290,10 @@ for(var i=0;i<aryButton.length;++i){var item=aryButton[i];var size=item.Style.Si
|
|
|
2286
2290
|
this.Canvas.fillStyle=this.ButtonTooltip.Color;this.Canvas.fillText(text,x+4,y+bgHeight/2);};//isLimit 是否限制在当前坐标下
|
|
2287
2291
|
this.GetYFromData=function(value,isLimit){if(this.Logarithmic&&this.GetYLogarithmicFromData){return this.GetYLogarithmicFromData(value,isLimit);}if(isLimit===false){if(this.CoordinateType==1){var height=this.ChartBorder.GetHeightEx()*(value-this.HorizontalMin)/(this.HorizontalMax-this.HorizontalMin);return this.ChartBorder.GetTopEx()+height;}else{var height=this.ChartBorder.GetHeightEx()*(value-this.HorizontalMin)/(this.HorizontalMax-this.HorizontalMin);return this.ChartBorder.GetBottomEx()-height;}}else{if(this.CoordinateType==1){if(value<=this.HorizontalMin)return this.ChartBorder.GetTopEx();if(value>=this.HorizontalMax)return this.ChartBorder.GetBottomEx();var height=this.ChartBorder.GetHeightEx()*(value-this.HorizontalMin)/(this.HorizontalMax-this.HorizontalMin);return this.ChartBorder.GetTopEx()+height;}else{if(value<=this.HorizontalMin)return this.ChartBorder.GetBottomEx();if(value>=this.HorizontalMax)return this.ChartBorder.GetTopEx();var height=this.ChartBorder.GetHeightEx()*(value-this.HorizontalMin)/(this.HorizontalMax-this.HorizontalMin);return this.ChartBorder.GetBottomEx()-height;}}};//画Y轴
|
|
2288
2292
|
this.DrawHorizontal=function(){this.RightTextMaxWidth=0;if(!IFrameSplitOperator.IsNonEmptyArray(this.HorizontalInfo))return;if(this.ChartBorder.IsShowTitleOnly)return;var border=this.ChartBorder.GetBorder();var left=border.Left;var right=border.Right;var bottom=border.Bottom;var top=this.ChartBorder.GetTop();var borderRight=this.ChartBorder.Right;var borderLeft=this.ChartBorder.Left;var isDrawLeft=borderLeft>10&&this.IsShowYText[0]===true&&this.YTextPosition[0]!=2;var isDrawRight=borderRight>10&&this.IsShowYText[1]===true&&this.YTextPosition[1]!=2;var rightExtendLine=null;//右侧延长线
|
|
2289
|
-
|
|
2290
|
-
if(IFrameSplitOperator.IsNonEmptyArray(this.
|
|
2293
|
+
var leftExtendLine=null;//左侧延长线
|
|
2294
|
+
if(IFrameSplitOperator.IsNonEmptyArray(this.YLineExtend)){rightExtendLine=this.YLineExtend[1];leftExtendLine=this.YLineExtend[0];}var rightExtendText=null;//右侧文字设置
|
|
2295
|
+
var leftExtendText=null;//左侧文字设置
|
|
2296
|
+
if(IFrameSplitOperator.IsNonEmptyArray(this.YTextExtend)){leftExtendText=this.YTextExtend[0];rightExtendText=this.YTextExtend[1];}var yPrev=null;//上一个坐标y的值
|
|
2291
2297
|
var pixelRatio=GetDevicePixelRatio();var itemHeight=(border.BottomEx-border.TopEx)/this.HorizontalInfo.length;var aryMultiText=[];var rtPreRight,rtRight,rtLeft,rtPreLeft;var textBaseline=0;//0=上 1=中 2=下
|
|
2292
2298
|
for(var i=this.HorizontalInfo.length-1;i>=0;--i)//从上往下画分割线
|
|
2293
2299
|
{var item=this.HorizontalInfo[i];var y=this.GetYFromData(item.Value);if(y!=null&&yPrev!=null&&Math.abs(y-yPrev)<this.MinYDistance)continue;//两个坐标在近了 就不画了
|
|
@@ -2298,13 +2304,13 @@ this.Canvas.beginPath();this.Canvas.moveTo(left,yFixed);this.Canvas.lineTo(right
|
|
|
2298
2304
|
{}else if(item.LineType==8||item.LineType==9)//集合竞价不画线
|
|
2299
2305
|
{}else if(item.LineType>0){if(g_JSChartResource.FrameYLineDash){this.Canvas.save();this.Canvas.setLineDash(g_JSChartResource.FrameYLineDash);//虚线
|
|
2300
2306
|
this.Canvas.beginPath();this.Canvas.moveTo(left,yFixed);this.Canvas.lineTo(right,yFixed);this.Canvas.stroke();this.Canvas.setLineDash([]);this.Canvas.restore();}else{this.Canvas.beginPath();this.Canvas.moveTo(left,yFixed);this.Canvas.lineTo(right,yFixed);this.Canvas.stroke();}}if(bChangeLineWidth){this.Canvas.lineWidth=pixelRatio;}}var yText=y;if(y>=bottom-2){this.Canvas.textBaseline='bottom';textBaseline=2;}else if(y<=top+2){this.Canvas.textBaseline='top';yText+=this.YTextTopOffset;textBaseline=0;}else{this.Canvas.textBaseline="middle";textBaseline=1;}//左边 坐标信息 间距小于10 不画坐标
|
|
2301
|
-
this.Canvas.strokeStyle=item.TextColor;this.Canvas.fillStyle=item.TextColor;if(item.Message[0]!=null&&isDrawLeft){if(item.Font!=null)this.Canvas.font=item.Font;rtLeft=this.GetTextTopBottom(textBaseline,yText);if(!rtPreLeft||rtLeft&&!this.IsTextTopBottomOverlap(rtLeft,rtPreLeft)){this.Canvas.textAlign="right";this.Canvas.fillText(item.Message[0],
|
|
2307
|
+
this.Canvas.strokeStyle=item.TextColor;this.Canvas.fillStyle=item.TextColor;if(item.Message[0]!=null&&isDrawLeft){if(item.Font!=null)this.Canvas.font=item.Font;var xText=left;if(leftExtendLine&&leftExtendLine.Width>1){var lineLength=leftExtendLine.Width;if(leftExtendLine.Color)this.Canvas.strokeStyle=leftExtendLine.Color;else this.Canvas.strokeStyle=item.LineColor;this.Canvas.beginPath();this.Canvas.moveTo(xText,yFixed);this.Canvas.lineTo(xText-lineLength,yFixed);this.Canvas.stroke();xText-=lineLength;}rtLeft=this.GetTextTopBottom(textBaseline,yText);if(!rtPreLeft||rtLeft&&!this.IsTextTopBottomOverlap(rtLeft,rtPreLeft)){if(leftExtendText&&leftExtendText.Align===1){this.Canvas.textAlign="left";this.Canvas.fillText(item.Message[0],this.YTextPadding[0],yText);}else{this.Canvas.textAlign="right";this.Canvas.fillText(item.Message[0],xText-this.YTextPadding[0],yText);rtPreLeft=rtLeft;}}}//右边 坐标信息 间距小于10 不画坐标
|
|
2302
2308
|
if(item.Message[1]!=null&&isDrawRight){if(item.Font!=null)this.Canvas.font=item.Font;var xText=right;if(item.LineType==3){var lineLength=this.ShortYLineLength*GetDevicePixelRatio();this.Canvas.beginPath();this.Canvas.moveTo(xText,yFixed);this.Canvas.lineTo(xText+lineLength,yFixed);this.Canvas.stroke();xText+=lineLength;}//右侧延长线
|
|
2303
2309
|
if(rightExtendLine&&rightExtendLine.Width>1){var lineLength=rightExtendLine.Width;if(rightExtendLine.Color)this.Canvas.strokeStyle=rightExtendLine.Color;else this.Canvas.strokeStyle=item.LineColor;this.Canvas.beginPath();this.Canvas.moveTo(xText,yFixed);this.Canvas.lineTo(xText+lineLength,yFixed);this.Canvas.stroke();xText+=lineLength+2;}this.Canvas.textAlign="left";if(Array.isArray(item.Message[1])){if(this.MultiTextFormat==1)//显示1行 格式:价格/百分比
|
|
2304
2310
|
{if(item.ExtendData){if(item.ExtendData.Font)this.Canvas.font=item.ExtendData.Font;}var textData={Text:[{Text:item.Message[1][0],Width:this.Canvas.measureText(item.Message[1][0]).width},{Text:item.Message[1][1],Width:this.Canvas.measureText(item.Message[1][1]).width}],X:xText+2,Y:yText,TextBaseline:this.Canvas.textBaseline,Item:item};aryMultiText.push(textData);}else if(this.MultiTextFormat==2)//显示2行
|
|
2305
2311
|
{this.Canvas.fillText(item.Message[1][0],xText+this.YTextPadding[1],yText);var lineHeight=this.Canvas.measureText('M').width;if(itemHeight>lineHeight*2)this.Canvas.fillText(item.Message[1][1],xText+this.YTextPadding[1],yText+lineHeight);}else//显示第1行
|
|
2306
2312
|
{this.Canvas.fillText(item.Message[1][0],xText+this.YTextPadding[1],yText);}}else{//计算显示的区域
|
|
2307
|
-
rtRight=this.GetTextTopBottom(textBaseline,yText);if(!rtPreRight||rtRight&&!this.IsTextTopBottomOverlap(rtRight,rtPreRight)){if(item.TextColor2)this.Canvas.fillStyle=item.TextColor2;if(rightExtendText&&rightExtendText.Align&&this.YRightTextInfo){this.Canvas.textAlign="right";var xRight=this.YRightTextInfo.MainTextWidth+right-this.YTextPadding[1];this.Canvas.fillText(item.Message[1],xRight,yText);}else{this.Canvas.fillText(item.Message[1],xText+this.YTextPadding[1],yText);}rtPreRight=rtRight;}}}yPrev=y;}if(IFrameSplitOperator.IsNonEmptyArray(aryMultiText)&&this.MultiTextFormat==1)this.DrawHorizontalMuText(aryMultiText);if(isDrawRight&&this.IsDrawRightBorder&&this.YRightTextInfo){var xRight=this.YRightTextInfo.MainTextWidth+right;xLine=ToFixedPoint(xRight);this.Canvas.strokeStyle=this.PenBorder;this.Canvas.beginPath();this.Canvas.moveTo(xLine,top);this.Canvas.lineTo(xLine,bottom);this.Canvas.stroke();if(IFrameSplitOperator.IsNonEmptyArray(this.YRightTextInfo.AryOverlayWidth)){this.Canvas.beginPath();for(var i=0;i<this.YRightTextInfo.AryOverlayWidth.length;++i){var width=this.YRightTextInfo.AryOverlayWidth[i];xRight+=width;xLine=ToFixedPoint(xRight);this.Canvas.moveTo(xLine,top);this.Canvas.lineTo(xLine,bottom);}this.Canvas.stroke();}}};//上下区域是否重叠
|
|
2313
|
+
rtRight=this.GetTextTopBottom(textBaseline,yText);if(!rtPreRight||rtRight&&!this.IsTextTopBottomOverlap(rtRight,rtPreRight)){if(item.TextColor2)this.Canvas.fillStyle=item.TextColor2;if(rightExtendText&&rightExtendText.Align===2&&this.YRightTextInfo){this.Canvas.textAlign="right";var xRight=this.YRightTextInfo.MainTextWidth+right-this.YTextPadding[1];this.Canvas.fillText(item.Message[1],xRight,yText);}else{this.Canvas.fillText(item.Message[1],xText+this.YTextPadding[1],yText);}rtPreRight=rtRight;}}}yPrev=y;}if(IFrameSplitOperator.IsNonEmptyArray(aryMultiText)&&this.MultiTextFormat==1)this.DrawHorizontalMuText(aryMultiText);if(isDrawRight&&this.IsDrawRightBorder&&this.YRightTextInfo){var xRight=this.YRightTextInfo.MainTextWidth+right;xLine=ToFixedPoint(xRight);this.Canvas.strokeStyle=this.PenBorder;this.Canvas.beginPath();this.Canvas.moveTo(xLine,top);this.Canvas.lineTo(xLine,bottom);this.Canvas.stroke();if(IFrameSplitOperator.IsNonEmptyArray(this.YRightTextInfo.AryOverlayWidth)){this.Canvas.beginPath();for(var i=0;i<this.YRightTextInfo.AryOverlayWidth.length;++i){var width=this.YRightTextInfo.AryOverlayWidth[i];xRight+=width;xLine=ToFixedPoint(xRight);this.Canvas.moveTo(xLine,top);this.Canvas.lineTo(xLine,bottom);}this.Canvas.stroke();}}};//上下区域是否重叠
|
|
2308
2314
|
this.IsTextTopBottomOverlap=function(rt,rt2){if(rt2.Top>=rt.Top&&rt2.Top<=rt.Bottom)return true;if(rt2.Bottom>=rt.Top&&rt2.Bottom<=rt.Bottom)return true;return false;};this.GetTextTopBottom=function(textBaseline,yText){var rtRight=null;var textHeight=this.Canvas.measureText('擎').width;if(textBaseline==0){rtRight={Top:yText,Bottom:yText+textHeight};}else if(textBaseline==1){rtRight={Top:yText-textHeight/2};rtRight.Bottom=rtRight.Top+textHeight;}else if(textBaseline==2){rtRight={Bottom:yText};rtRight.Top=rtRight.Bottom-textHeight;}return rtRight;};this.DrawHorizontalMuText=function(aryText){var maxWidth=[null,null];for(var i=0;i<aryText.length;++i){var item=aryText[i];var width=item.Text[0].Width;if(!IFrameSplitOperator.IsNumber(maxWidth[0]))maxWidth[0]=width;else if(maxWidth[0]<width)maxWidth[0]=width;width=item.Text[1].Width;if(!IFrameSplitOperator.IsNumber(maxWidth[1]))maxWidth[1]=width;else if(maxWidth[1]<width)maxWidth[1]=width;}for(var i=0;i<aryText.length;++i){var item=aryText[i];var message=item.Item;this.Canvas.textBaseline=message.TextBaseline;if(message.ExtendData&&message.ExtendData.Font)this.Canvas.font=message.ExtendData.Font;else if(message.Font)this.Canvas.font=message.Font;if(message.ExtendData&&message.ExtendData.PriceColor)this.Canvas.fillStyle=message.ExtendData.PriceColor;else this.Canvas.fillStyle=message.TextColor;this.Canvas.textAlign="right";var x=item.X+maxWidth[1];this.Canvas.fillText(item.Text[1].Text,x,item.Y);if(message.ExtendData&&message.ExtendData.SplitColor)this.Canvas.fillStyle=message.ExtendData.SplitColor;else this.Canvas.fillStyle=message.TextColor;this.Canvas.textAlign="left";var splitWidth=this.Canvas.measureText('/').width;this.Canvas.fillText('/',x,item.Y);if(message.ExtendData&&message.ExtendData.PercentageColor)this.Canvas.fillStyle=message.ExtendData.PercentageColor;else this.Canvas.fillStyle=message.TextColor;this.Canvas.textAlign="right";var x=item.X+maxWidth[1]+maxWidth[0]+splitWidth;this.Canvas.fillText(item.Text[0].Text,x,item.Y);var textWidth=maxWidth[1]+maxWidth[0]+splitWidth*4;if(this.RightTextMaxWidth<textWidth)this.RightTextMaxWidth=textWidth;}};//画Y轴Message[2,3]两个内部刻度
|
|
2309
2315
|
this.DrawInsideClientHorizontal=function(){var border=this.GetBorder();if(border.DayBorder&&IFrameSplitOperator.IsNonEmptyArray(border.DayBorder)){var item=border.DayBorder[0];var left=item.LeftEx;var item=border.DayBorder[border.DayBorder.length-1];var right=item.RightEx;var bottom=border.Bottom;var top=border.TopTitle;}else{var left=border.LeftEx;var right=border.RightEx;var bottom=border.Bottom;var top=border.TopTitle;}var pixelTatio=GetDevicePixelRatio();var yPrev=null;//上一个坐标y的值
|
|
2310
2316
|
var yInsideText=null;for(var i=this.HorizontalInfo.length-1;i>=0;--i)//从上往下画分割线
|
|
@@ -2342,12 +2348,12 @@ var textLeft=yText-textHeight/2-1*pixelTatio;this.Canvas.fillStyle=item.LineColo
|
|
|
2342
2348
|
var width=this.Canvas.measureText(item.Title).width+2*pixelTatio;if(this.IsHScreen){var bgTop=bottom-width;var textLeft=y-textHeight/2-1*pixelTatio;this.Canvas.fillStyle=bgColor;this.Canvas.fillRect(textLeft,bgTop,textHeight,width);this.DrawHScreenText({X:y,Y:bgTop},{Text:item.Title,Color:item.TextColor,XOffset:1*pixelTatio,YOffset:2*pixelTatio});}else{var bgTop=y-textHeight/2-1*pixelTatio;var textLeft=right-width-1*pixelTatio;this.Canvas.fillStyle=bgColor;this.Canvas.fillRect(textLeft,bgTop,width,textHeight);this.Canvas.fillStyle=item.TextColor;this.Canvas.fillText(item.Title,textLeft+1*pixelTatio,y);}}}}}};this.SendDrawCountDownEvent=function(sendData){if(!this.GetEventCallback)return false;var event=this.GetEventCallback(JSCHART_EVENT_ID.ON_DRAW_COUNTDOWN);if(!event||!event.Callback)return false;event.Callback(event,sendData,this);return true;};this.DrawDotLine=function(left,right,y,color,option){var pixelTatio=GetDevicePixelRatio();this.Canvas.save();this.Canvas.strokeStyle=color;if(option&&IFrameSplitOperator.IsPlusNumber(option.LineWidth))this.Canvas.lineWidth=option.LineWidth*pixelTatio;if(option.LineDash)this.Canvas.setLineDash(option.LineDash);else this.Canvas.setLineDash([5*pixelTatio,5*pixelTatio]);//虚线
|
|
2343
2349
|
this.Canvas.beginPath();if(this.IsHScreen){this.Canvas.moveTo(ToFixedPoint(y),left);this.Canvas.lineTo(ToFixedPoint(y),right);}else{this.Canvas.moveTo(left,ToFixedPoint(y));this.Canvas.lineTo(right,ToFixedPoint(y));}this.Canvas.stroke();this.Canvas.restore();};this.DrawLine=function(left,right,y,color,lineType,option){if(lineType==-1)return;if(lineType==0){var pixelRatio=GetDevicePixelRatio();this.Canvas.strokeStyle=color;var bChangeLineWidth=false;if(option&&IFrameSplitOperator.IsPlusNumber(option.LineWidth)){this.Canvas.lineWidth=option.LineWidth*pixelRatio;bChangeLineWidth=true;}this.Canvas.beginPath();if(this.IsHScreen){this.Canvas.moveTo(ToFixedPoint(y),left);this.Canvas.lineTo(ToFixedPoint(y),right);}else{this.Canvas.moveTo(left,ToFixedPoint(y));this.Canvas.lineTo(right,ToFixedPoint(y));}this.Canvas.stroke();if(bChangeLineWidth){this.Canvas.lineWidth=pixelRatio;}}else{this.DrawDotLine(left,right,y,color,option);}};this.DrawHScreenText=function(center,data){this.Canvas.textAlign="left";this.Canvas.textBaseline="middle";this.Canvas.fillStyle=data.Color;this.Canvas.save();this.Canvas.translate(center.X,center.Y);this.Canvas.rotate(90*Math.PI/180);this.Canvas.fillText(data.Text,data.XOffset,data.YOffset);this.Canvas.restore();};this.RGBToStruct=function(rgb){if(/^(rgb|RGB)/.test(rgb)){var aColor=rgb.replace(/(?:\(|\)|rgb|RGB)*/g,"").split(",");var result={};if(aColor.length!=3)return null;result.R=Number(aColor[0]);result.G=Number(aColor[1]);result.B=Number(aColor[2]);return result;}return null;};this.GetScaleTextWidth=function(){var border=this.ChartBorder.GetBorder();var pixelTatio=GetDevicePixelRatio();//获取设备的分辨率
|
|
2344
2350
|
if(this.IsHScreen){var borderTop=this.ChartBorder.Top;var borderBottom=this.ChartBorder.Bottom;var isDrawLeft=borderTop>10*pixelTatio&&this.IsShowYText[0]===true&&this.YTextPosition[0]!=2;var isDrawRight=borderBottom>10*pixelTatio&&this.IsShowYText[1]===true&&this.YTextPosition[1]!=2;}else{var borderRight=this.ChartBorder.Right;var borderLeft=this.ChartBorder.Left;var isDrawLeft=borderLeft>10&&this.IsShowYText[0]===true&&this.YTextPosition[0]!=2;var isDrawRight=borderRight>10&&this.IsShowYText[1]===true&&this.YTextPosition[1]!=2;}if(!isDrawRight&&!isDrawLeft)return null;var width={Left:null,Right:null};var rightExtendWidth=0;var isYPercentage=false;//是否是百分比坐标
|
|
2345
|
-
if(this.YSplitOperator&&this.YSplitOperator.CoordinateType==1)isYPercentage=true;for(var i=0;i<this.HorizontalInfo.length;++i){var textWidth=null;var item=this.HorizontalInfo[i];if(!item)continue;if(item.Font!=null)this.Canvas.font=item.Font;if(item.Message[0]!=null&&isDrawLeft){textWidth=this.Canvas.measureText(item.Message[0]).width;if(width.Left==null||width.Left<textWidth)width.Left=textWidth;//JSConsole.Chart.Log(`[ChartData::GetScaleTextWidth] ${item.Message[0]} ${textWidth}`);
|
|
2351
|
+
if(this.YSplitOperator&&this.YSplitOperator.CoordinateType==1)isYPercentage=true;var leftExtendLineWidth=0;var rightExtendLineWidth=0;if(IFrameSplitOperator.IsNonEmptyArray(this.YLineExtend)){if(this.YLineExtend[0]&&this.YLineExtend[0].Width>1)leftExtendLineWidth=this.YLineExtend[0].Width;if(this.YLineExtend[1]&&this.YLineExtend[1].Width>1)rightExtendLineWidth=this.YLineExtend[1].Width;}for(var i=0;i<this.HorizontalInfo.length;++i){var textWidth=null;var item=this.HorizontalInfo[i];if(!item)continue;if(item.Font!=null)this.Canvas.font=item.Font;if(item.Message[0]!=null&&isDrawLeft){textWidth=this.Canvas.measureText(item.Message[0]).width;if(width.Left==null||width.Left<textWidth)width.Left=textWidth;//JSConsole.Chart.Log(`[ChartData::GetScaleTextWidth] ${item.Message[0]} ${textWidth}`);
|
|
2346
2352
|
}if(item.Message[1]!=null&&isDrawRight){if(item.Font!=null)this.Canvas.font=item.Font;if(Array.isArray(item.Message[1])){if(this.MultiTextFormat==1)//显示1行 格式:价格/百分比
|
|
2347
2353
|
{if(item.ExtendData){if(item.ExtendData.Font)this.Canvas.font=item.ExtendData.Font;var width1=this.Canvas.measureText(item.Message[1][0]).width;var width2=this.Canvas.measureText(item.Message[1][1]).width;var width3=this.Canvas.measureText('/').width;textWidth=width1+width3;if(rightExtendWidth<width2)rightExtendWidth=width2;//JSConsole.Chart.Log(`[ChartData::GetScaleTextWidth] ${item.Message[1][1]}/${item.Message[1][0]} ${textWidth}, ${rightExtendWidth}`);
|
|
2348
2354
|
}}else if(this.MultiTextFormat==2)//显示2行
|
|
2349
2355
|
{textWidth=this.Canvas.measureText(item.Message[1][0]).width;var textWidth2=this.Canvas.measureText(item.Message[1][1]).width;if(textWidth<textWidth2)textWidth=textWidth2;}else//显示第1行
|
|
2350
|
-
{textWidth=this.Canvas.measureText(item.Message[1][0]).width;if(isYPercentage){var perTextWidth=this.Canvas.measureText("-00.00%").width;if(perTextWidth>textWidth)textWidth=perTextWidth;}}}else{textWidth=this.Canvas.measureText(item.Message[1]).width;}if(width.Right==null||width.Right<textWidth)width.Right=textWidth;}}if(IFrameSplitOperator.IsNumber(width.Right))width.Right+=rightExtendWidth;if(IFrameSplitOperator.IsNumber(width.Left))width.Left+=this.YTextPadding[0];if(IFrameSplitOperator.IsNumber(width.Right))width.Right+=this.YTextPadding[1];return{TextWidth:width};};this.ClearToolbar=function(){if(!this.ToolbarID)return;var divToolbar=document.getElementById(this.ToolbarID);if(!divToolbar)return;this.ChartBorder.UIElement.parentNode.removeChild(divToolbar);this.ToolbarRect=null;};this.HideToolbar=function(){if(!this.ToolbarID)return;this.ToolbarRect=null;var divToolbar=document.getElementById(this.ToolbarID);if(!divToolbar)return;if(divToolbar.style.display!='none')divToolbar.style.display='none';};}function MinuteFrame(){this.newMethod=AverageWidthFrame;//派生
|
|
2356
|
+
{textWidth=this.Canvas.measureText(item.Message[1][0]).width;if(isYPercentage){var perTextWidth=this.Canvas.measureText("-00.00%").width;if(perTextWidth>textWidth)textWidth=perTextWidth;}}}else{textWidth=this.Canvas.measureText(item.Message[1]).width;}if(width.Right==null||width.Right<textWidth)width.Right=textWidth;}}if(IFrameSplitOperator.IsNumber(width.Right))width.Right+=rightExtendWidth;if(IFrameSplitOperator.IsNumber(width.Left))width.Left+=this.YTextPadding[0]+leftExtendLineWidth;if(IFrameSplitOperator.IsNumber(width.Right))width.Right+=this.YTextPadding[1]+rightExtendLineWidth;return{TextWidth:width};};this.ClearToolbar=function(){if(!this.ToolbarID)return;var divToolbar=document.getElementById(this.ToolbarID);if(!divToolbar)return;this.ChartBorder.UIElement.parentNode.removeChild(divToolbar);this.ToolbarRect=null;};this.HideToolbar=function(){if(!this.ToolbarID)return;this.ToolbarRect=null;var divToolbar=document.getElementById(this.ToolbarID);if(!divToolbar)return;if(divToolbar.style.display!='none')divToolbar.style.display='none';};}function MinuteFrame(){this.newMethod=AverageWidthFrame;//派生
|
|
2351
2357
|
this.newMethod();delete this.newMethod;this.ClassName="MinuteFrame";this.DataWidth=1*GetDevicePixelRatio();this.DistanceWidth=1*GetDevicePixelRatio();this.MinuteCount=243;//每天的分钟个数
|
|
2352
2358
|
this.BeforeBGColor=g_JSChartResource.Minute.Before.BGColor;//集合竞价背景
|
|
2353
2359
|
this.AfterBGColor=g_JSChartResource.Minute.After.BGColor;this.MultiDayBorderPen=g_JSChartResource.MultiDayBorderPen;this.CustomHorizontalInfo=[];this.RightFrame=null;//右侧多重坐标
|
|
@@ -11410,7 +11416,7 @@ else if(value.indexOf('LINEOVERLAY')==0)isOverlayLine=true;else if(value.indexOf
|
|
|
11410
11416
|
{var outVar={Name:_drawName,Draw:outValue,Type:1};this.OutVarTable.push(outVar);}else if(colorStick&&_varName7)//CYW: SUM(VAR4,10)/10000, COLORSTICK; 画上下柱子
|
|
11411
11417
|
{outValue+=",画彩色柱状线";var _value21={Name:_varName7,Draw:outValue,Color:color,Type:2};this.OutVarTable.push(_value21);}else if(_varName7){var _value22={Name:_varName7,Data:outValue,Type:0};this.OutVarTable.push(_value22);}}}}JSConsole.Complier.Log('[JSExplainer::Run]',this.VarTable);return this.OutVarTable;};this.VisitNode=function(node){switch(node.Type){case Syntax.SequenceExpression:this.VisitSequenceExpression(node);break;case Syntax.ExpressionStatement:this.VisitNode(node.Expression);break;case Syntax.AssignmentExpression:this.VisitAssignmentExpression(node);break;case Syntax.BinaryExpression:case Syntax.LogicalExpression:this.VisitBinaryExpression(node);break;case Syntax.CallExpression:this.VisitCallExpression(node);break;}};this.VisitSequenceExpression=function(node){for(var _i148 in node.Expression){var _item28=node.Expression[_i148];this.VisitNode(_item28);}};//函数调用
|
|
11412
11418
|
this.VisitCallExpression=function(node){var funcName=node.Callee.Name;var args=[];for(var _i149 in node.Arguments){var _item29=node.Arguments[_i149];var value=void 0;if(_item29.Type==Syntax.BinaryExpression||_item29.Type==Syntax.LogicalExpression)value=this.VisitBinaryExpression(_item29);else if(_item29.Type==Syntax.CallExpression)value=this.VisitCallExpression(_item29);else value=this.GetNodeValue(_item29);args.push(value);}JSConsole.Complier.Log('[JSExplainer::VisitCallExpression]',funcName,'(',args.toString(),')');if(g_JSComplierResource.IsCustomFunction(funcName)){var data=this.Algorithm.CallCustomFunction(funcName,args,this.SymbolData,node);node.Out=[];node.Draw=null;if(data){if(data.Out)node.Out=data.Out;if(data.Draw)node.Draw=data.Draw;}return node.Out;}node.Out=this.CallFunctionExplain(funcName,args,node);return node.Out;};this.FUNCTION_INFO_LIST=new _map2.default([["REF",{Name:"REF",Param:{Count:2},ToString:function ToString(args){return args[1]+'\u65E5\u524D\u7684'+args[0];}}],["REFX",{Name:"REFX",Param:{Count:2},ToString:function ToString(args){return args[1]+'\u65E5\u540E\u7684'+args[0];}}],["REFV",{Name:"REFV",Param:{Count:2},ToString:function ToString(args){return args[1]+'\u65E5\u524D\u7684(\u672A\u4F5C\u5E73\u6ED1\u5904\u7406)'+args[0];}}],["REFXV",{Name:"REFXV",Param:{Count:2},ToString:function ToString(args){return args[1]+'\u65E5\u540E\u7684(\u672A\u4F5C\u5E73\u6ED1\u5904\u7406)'+args[0];}}],["REFDATE",{Name:"REFDATE",Param:{Count:2},ToString:function ToString(args){return args[1]+'\u65E5'+args[0];}}],["COUNT",{Name:"COUNT",Param:{Count:2},ToString:function ToString(args){return'\u7EDF\u8BA1'+args[1]+'\u65E5\u4E2D\u6EE1\u8DB3'+args[0]+'\u7684\u5929\u6570';}}],["BARSLASTCOUNT",{Name:"BARSLASTCOUNT",Param:{Count:1},ToString:function ToString(args){return'\u6761\u4EF6'+args[0]+'\u8FDE\u7EED\u6210\u7ACB\u6B21\u6570';}}],["BARSCOUNT",{Name:"BARSCOUNT",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u6709\u6548\u6570\u636E\u5468\u671F\u6570';}}],["BARSLAST",{Name:"BARSLAST",Param:{Count:1},ToString:function ToString(args){return'\u4E0A\u6B21'+args[0]+'\u4E0D\u4E3A0\u8DDD\u4ECA\u5929\u6570';}}],["BARSNEXT",{Name:"BARSNEXT",Param:{Count:1},ToString:function ToString(args){return'\u4E0B\u6B21'+args[0]+'\u4E0D\u4E3A0\u8DDD\u4ECA\u5929\u6570';}}],["BARSSINCEN",{Name:"BARSSINCEN",Param:{Count:2},ToString:function ToString(args){return'\u5728'+args[1]+'\u5468\u671F\u5185\u9996\u6B21'+args[0]+'\u8DDD\u4ECA\u5929\u6570';}}],["BARSSINCE",{Name:"BARSSINCE",Param:{Count:1},ToString:function ToString(args){return'\u9996\u6B21'+args[0]+'\u8DDD\u4ECA\u5929\u6570';}}],["HHV",{Name:"HHV",Param:{Count:2},ToString:function ToString(args){return args[1]+'\u65E5\u5185'+args[0]+'\u7684\u6700\u9AD8\u503C';}}],["LLV",{Name:"LLV",Param:{Count:2},ToString:function ToString(args){return args[1]+'\u65E5\u5185'+args[0]+'\u7684\u6700\u4F4E\u503C';}}],["ZTPRICE",{Name:"ZTPRICE",Param:{Count:2},ToString:function ToString(args){return'计算涨停价';}}],["DTPRICE",{Name:"DTPRICE",Param:{Count:2},ToString:function ToString(args){return'计算跌停价';}}],["BACKSET",{Name:"BACKSET",Param:{Count:2},ToString:function ToString(args){return'\u82E5'+args[0]+'\u5219\u5C06\u6700\u8FD1'+args[1]+'\u5468\u671F\u7F6E\u4E3A1';}}],["HOD",{Name:"HOD",Param:{Count:2},ToString:function ToString(args){return args[1]+'\u65E5\u5185'+args[0]+'\u7684\u9AD8\u503C\u540D\u6B21';}}],["LOD",{Name:"LOD",Param:{Count:2},ToString:function ToString(args){return args[1]+'\u65E5\u5185'+args[0]+'\u7684\u4F4E\u503C\u540D\u6B21';}}],["REVERSE",{Name:"REVERSE",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u76F8\u53CD\u6570';}}],["FILTER",{Name:"FILTER",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u8FC7\u6EE4';}}],["FILTERX",{Name:"FILTERX",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u53CD\u5411\u8FC7\u6EE4';}}],["TFILTER",{Name:"TFILTER",Param:{Count:3},ToString:function ToString(args){return'\u4FE1\u53F7\u8FC7\u6EE4(\u591A\u5934)';}}],["SUMBARS",{Name:"SUMBARS",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7D2F\u52A0\u81F3'+args[1]+'\u7684\u5929\u6570';}}],["MA",{Name:"MA",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u7B80\u5355\u79FB\u52A8\u5E73\u5747';}}],["SMA",{Name:"SMA",Param:{Count:3},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5['+args[2]+'\u65E5\u6743\u91CD]\u79FB\u52A8\u5E73\u5747';}}],["MEMA",{Name:"MEMA",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u5E73\u6ED1\u79FB\u52A8\u5E73\u5747';}}],["EMA",{Name:"EMA",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u6307\u6570\u79FB\u52A8\u5E73\u5747';}}],["EXPMA",{Name:"EXPMA",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u6307\u6570\u79FB\u52A8\u5E73\u5747';}}],["EXPMEMA",{Name:"EXPMEMA",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u6307\u6570\u5E73\u6ED1\u79FB\u52A8\u5E73\u5747';}}],["WMA",{Name:"WMA",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u52A0\u6743\u79FB\u52A8\u5E73\u5747';}}],["DMA",{Name:"DMA",Param:{Count:2},ToString:function ToString(args){return'\u4EE5'+args[1]+'\u4E3A\u6743\u91CD'+args[0]+'\u7684\u52A8\u6001\u79FB\u52A8\u5E73\u5747';}}],["XMA",{Name:"XMA",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u504F\u79FB\u79FB\u52A8\u5E73\u5747';}}],["RANGE",{Name:"RANGE",Param:{Count:3},ToString:function ToString(args){return args[0]+'\u4F4D\u4E8E'+args[1]+'\u548C'+args[2]+'\u4E4B\u95F4';}}],["CONST",{Name:"CONST",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u6700\u540E\u4E00\u65E5\u503C';}}],["TOPRANGE",{Name:"TOPRANGE",Param:{Count:1},ToString:function ToString(args){return'\u5F53\u524D\u503C\u662F\u8FD1'+args[0]+'\u5468\u671F\u7684\u6700\u5927\u503C';}}],["LOWRANGE",{Name:"LOWRANGE",Param:{Count:1},ToString:function ToString(args){return'\u5F53\u524D\u503C\u662F\u8FD1'+args[0]+'\u5468\u671F\u7684\u6700\u5C0F\u503C';}}],["FINDHIGH",{Name:"FINDHIGH",Param:{Count:4},ToString:function ToString(args){return args[0]+'\u5728'+args[1]+'\u65E5\u524D\u7684'+args[2]+'\u5929\u5185\u7B2C'+args[3]+'\u4E2A\u6700\u9AD8\u4EF7';}}],["FINDHIGHBARS",{Name:"FINDHIGHBARS",Param:{Count:4},ToString:function ToString(args){return args[0]+'\u5728'+args[1]+'\u65E5\u524D\u7684'+args[2]+'\u5929\u5185\u7B2C'+args[3]+'\u4E2A\u6700\u9AD8\u4EF7\u5230\u5F53\u524D\u5468\u671F\u7684\u5468\u671F\u6570';}}],["FINDLOW",{Name:"FINDLOW",Param:{Count:4},ToString:function ToString(args){return args[0]+'\u5728'+args[1]+'\u65E5\u524D\u7684'+args[2]+'\u5929\u5185\u7B2C'+args[3]+'\u4E2A\u6700\u4F4E\u4EF7';}}],["FINDLOWBARS",{Name:"FINDLOWBARS",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u5728'+args[1]+'\u65E5\u524D\u7684'+args[2]+'\u5929\u5185\u7B2C'+args[3]+'\u4E2A\u6700\u4F4E\u4EF7\u5230\u5F53\u524D\u5468\u671F\u7684\u5468\u671F\u6570';}}],["SUM",{Name:"SUM",Param:{Count:2},ToString:function ToString(args){return''+args[0]+args[1]+'\u65E5\u7D2F\u52A0';}}],["MULAR",{Name:"MULAR",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u548C'+args[1]+'\u65E5\u7D2F\u4E58';}}],["AMA",{Name:"AMA",Param:{Count:2},ToString:function ToString(args){return'\u4EE5'+args[1]+'\u4E3A\u6743\u91CD'+args[0]+'\u7684\u81EA\u9002\u5E94\u5747\u7EBF';}}],["TMA",{Name:"TMA",Param:{Count:3},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5['+args[2]+'\u65E5\u6743\u91CD]\u79FB\u52A8\u5E73\u5747';}}],["CROSS",{Name:"CROSS",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u4E0A\u7A7F'+args[1];}}],["LONGCROSS",{Name:"LONGCROSS",Param:{Count:3},ToString:function ToString(args){return args[0]+'\u5C0F\u4E8E'+args[1]+'\u4FDD\u6301'+args[2]+'\u4E2A\u4EA4\u6613\u65E5\u540E\u4EA4\u53C9\u4E0A\u7A7F';}}],["UPNDAY",{Name:"UPNDAY",Param:{Count:2},ToString:function ToString(args){return'\u6700\u8FD1'+args[1]+'\u65E5'+args[0]+'\u8FDE\u6DA8';}}],["DOWNNDAY",{Name:"DOWNNDAY",Param:{Count:2},ToString:function ToString(args){return'\u6700\u8FD1'+args[1]+'\u65E5'+args[0]+'\u8FDE\u8DCC';}}],["NDAY",{Name:"NDAY",Param:{Count:3},ToString:function ToString(args){return'\u6700\u8FD1'+args[2]+'\u65E5'+args[0]+'\u4E00\u76F4\u5927\u4E8E'+args[1];}}],["EXIST",{Name:"EXIST",Param:{Count:2},ToString:function ToString(args){return'\u6700\u8FD1'+args[1]+'\u65E5\u5B58\u5728'+args[0];}}],["EXISTR",{Name:"EXISTR",Param:{Count:3},ToString:function ToString(args){return'\u4ECE\u524D'+args[1]+'\u65E5\u5230\u524D'+args[2]+'\u65E5\u5B58\u5728'+args[0];}}],["EVERY",{Name:"EVERY",Param:{Count:2},ToString:function ToString(args){return'\u6700\u8FD1'+args[1]+'\u65E5\u4E00\u76F4\u5B58\u5728'+args[0];}}],["LAST",{Name:"LAST",Param:{Count:3},ToString:function ToString(args){return'\u4ECE\u524D'+args[1]+'\u65E5\u5230\u524D'+args[2]+'\u65E5\u6301\u7EED'+args[0];}}],["NOT",{Name:"NOT",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u53D6\u53CD';}}],["IF",{Name:"IF",Param:{Count:3},ToString:function ToString(args){return'\u5982\u679C'+args[0]+',\u8FD4\u56DE'+args[1]+',\u5426\u5219\u8FD4\u56DE'+args[2];}}],["IFF",{Name:"IFF",Param:{Count:3},ToString:function ToString(args){return'\u5982\u679C'+args[0]+',\u8FD4\u56DE'+args[1]+',\u5426\u5219\u8FD4\u56DE'+args[2];}}],["IFN",{Name:"IFN",Param:{Count:3},ToString:function ToString(args){return'\u5982\u679C'+args[0]+',\u8FD4\u56DE'+args[1]+',\u5426\u5219\u8FD4\u56DE'+args[2];}}],["IFC",{Name:"IFC",Param:{Count:3},ToString:function ToString(args){return'\u5982\u679C'+args[0]+',\u8FD4\u56DE'+args[1]+',\u5426\u5219\u8FD4\u56DE'+args[2];}}],["TESTSKIP",{Name:"TESTSKIP",Param:{Count:1},ToString:function ToString(args){return'\u5982\u679C\u6EE1\u8DB3\u6761\u4EF6'+args[0]+',\u516C\u5F0F\u8FD4\u56DE';}}],["VALUEWHEN",{Name:"VALUEWHEN",Param:{Count:2},ToString:function ToString(args){return'\u5982\u679C'+args[0]+',\u8FD4\u56DE'+args[1]+',\u5426\u5219\u8FD4\u56DE\u4E0A\u4E2A\u8F93\u51FA\u503C ';}}],["MAX",{Name:"MAX",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u548C'+args[1]+'\u7684\u8F83\u5927\u503C';}}],["MIN",{Name:"MIN",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u548C'+args[1]+'\u7684\u8F83\u5C0F\u503C';}}],["ACOS",{Name:"ACOS",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u53CD\u4F59\u5F26';}}],["ASIN",{Name:"ASIN",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u53CD\u6B63\u5F26';}}],["ATAN",{Name:"ATAN",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u53CD\u6B63\u5207';}}],["COS",{Name:"COS",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u4F59\u5F26';}}],["SIN",{Name:"SIN",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u6B63\u5F26';}}],["TAN",{Name:"TAN",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u6B63\u5207';}}],["EXP",{Name:"EXP",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u6307\u6570';}}],["LN",{Name:"LN",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u81EA\u7136\u5BF9\u6570';}}],["LOG",{Name:"LOG",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u5BF9\u6570';}}],["SQRT",{Name:"SQRT",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u5F00\u65B9';}}],["ABS",{Name:"ABS",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u7EDD\u5BF9\u503C';}}],["POW",{Name:"POW",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u4E58\u5E42';}}],["CEILING",{Name:"CEILING",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u5411\u4E0A\u820D\u5165';}}],["FLOOR",{Name:"FLOOR",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u5411\u4E0A\u820D\u5165';}}],["INTPART",{Name:"INTPART",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u6574\u6570\u90E8\u5206';}}],["BETWEEN",{Name:"BETWEEN",Param:{Count:3},ToString:function ToString(args){return args[0]+'\u4F4D\u4E8E'+args[1]+'\u548C'+args[2]+'\u4E4B\u95F4';}}],["FRACPART",{Name:"FRACPART",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u5C0F\u6570\u90E8\u5206';}}],["ROUND",{Name:"ROUND",Param:{Count:1},ToString:function ToString(args){return'\u5BF9'+args[0]+'(\u8FDB\u884C)\u56DB\u820D\u4E94\u5165';}}],["ROUND2",{Name:"ROUND2",Param:{Count:2},ToString:function ToString(args){return'\u5BF9'+args[0]+'(\u8FDB\u884C)\u56DB\u820D\u4E94\u5165';}}],["SIGN",{Name:"SIGN",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u7684\u7B26\u53F7';}}],["MOD",{Name:"MOD",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u5173\u4E8E'+args[1]+'\u7684\u6A21';}}],["RAND",{Name:"RAND",Param:{Count:1},ToString:function ToString(args){return'\u968F\u673A\u6B63\u6574\u6570';}}],["AVEDEV",{Name:"AVEDEV",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u5E73\u5747\u7EDD\u5BF9\u504F\u5DEE';}}],["DEVSQ",{Name:"DEVSQ",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u6570\u636E\u504F\u5DEE\u5E73\u65B9\u548C';}}],["FORCAST",{Name:"FORCAST",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u7EBF\u6027\u56DE\u5F52\u9884\u6D4B\u503C';}}],["TSMA",{Name:"TSMA",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u5728'+args[1]+'\u4E2A\u5468\u671F\u5185\u7684\u65F6\u95F4\u5E8F\u5217\u4E09\u89D2\u79FB\u52A8\u5E73\u5747';}}],["SLOPE",{Name:"SLOPE",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u7EBF\u6027\u56DE\u5F52\u659C\u7387';}}],["STD",{Name:"STD",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u4F30\u7B97\u6807\u51C6\u5DEE';}}],["STDP",{Name:"STDP",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u603B\u4F53\u6807\u51C6\u5DEE';}}],["STDDEV",{Name:"STDDEV",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u6807\u51C6\u504F\u5DEE';}}],["VAR",{Name:"VAR",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u4F30\u7B97\u6837\u672C\u65B9\u5DEE';}}],["VARP",{Name:"VARP",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u7684'+args[1]+'\u65E5\u603B\u4F53\u6837\u672C\u65B9\u5DEE';}}],["COVAR",{Name:"COVAR",Param:{Count:3},ToString:function ToString(args){return args[0]+'\u548C'+args[1]+'\u7684'+args[2]+'\u5468\u671F\u7684\u534F\u65B9\u5DEE';}}],["RELATE",{Name:"RELATE",Param:{Count:3},ToString:function ToString(args){return args[0]+'\u548C'+args[1]+'\u7684'+args[0]+'\u5468\u671F\u7684\u76F8\u5173\u7CFB\u6570';}}],["BETA",{Name:"BETA",Param:{Count:1},ToString:function ToString(args){return'\u03B2(Beta)\u7CFB\u6570';}}],["BETAEX",{Name:"BETAEX",Param:{Count:3},ToString:function ToString(args){return args[0]+'\u548C'+args[1]+'\u7684'+args[2]+'\u5468\u671F\u7684\u76F8\u5173\u653E\u5927\u7CFB\u6570';}}],["COST",{Name:"COST",Param:{Count:1},ToString:function ToString(args){return'\u83B7\u5229\u76D8\u4E3A'+args[0]+'%\u7684\u6210\u672C\u5206\u5E03';}}],["WINNER",{Name:"WINNER",Param:{Count:1},ToString:function ToString(args){return'\u4EE5'+args[0]+'\u8BA1\u7B97\u7684\u83B7\u5229\u76D8\u6BD4\u4F8B';}}],["LWINNER",{Name:"LWINNER",Param:{Count:2},ToString:function ToString(args){return'\u6700\u8FD1'+args[0]+'\u65E5\u90A3\u90E8\u5206\u6210\u672C\u4EE5'+args[1]+'\u4EF7\u683C\u5356\u51FA\u7684\u83B7\u5229\u76D8\u6BD4\u4F8B';}}],["PWINNER",{Name:"PWINNER",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u65E5\u524D\u90A3\u90E8\u5206\u6210\u672C\u4EE5'+args[1]+'\u4EF7\u683C\u5356\u51FA\u7684\u83B7\u5229\u76D8\u6BD4\u4F8B';}}],["COSTEX",{Name:"COSTEX",Param:{Count:2},ToString:function ToString(args){return'\u4F4D\u4E8E\u4EF7\u683C'+args[0]+'\u548C'+args[1]+'\u95F4\u7684\u6210\u672C';}}],["PPART",{Name:"PPART",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u65E5\u524D\u90A3\u90E8\u5206\u6210\u672C\u5360\u603B\u6210\u672C\u7684\u6BD4\u4F8B';}}],["SAR",{Name:"SAR",Param:{Count:3},ToString:function ToString(args){return'\u6B65\u957F\u4E3A'+args[1]+'\u6781\u9650\u503C\u4E3A'+args[0]+'\u7684'+args[2]+'\u65E5\u629B\u7269\u8F6C\u5411';}}],["SARTURN",{Name:"SARTURN",Param:{Count:3},ToString:function ToString(args){return'\u6B65\u957F\u4E3A'+args[1]+'\u6781\u9650\u503C\u4E3A'+args[0]+'\u7684'+args[2]+'\u65E5\u629B\u7269\u8F6C\u5411\u70B9';}}],//字符串函数
|
|
11413
|
-
["CON2STR",{Name:"CON2STR",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u8F6C\u4E3A\u5B57\u7B26\u4E32';}}],["VAR2STR",{Name:"VAR2STR",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u8F6C\u4E3A\u5B57\u7B26\u4E32';}}],["STR2CON",{Name:"STR2CON",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u8F6C\u4E3A\u6570\u5B57';}}],["STRLEN",{Name:"STRLEN",Param:{Count:1},ToString:function ToString(args){return'\u5F97\u5230'+args[0]+'\u5B57\u7B26\u4E32\u957F\u5EA6';}}],["STRCAT",{Name:"STRCAT",Param:{Count:2},ToString:function ToString(args){return'\u5B57\u7B26\u4E32\u76F8\u52A0';}}],["VARCAT",{Name:"VARCAT",Param:{Count:2},ToString:function ToString(args){return'\u5B57\u7B26\u4E32\u76F8\u52A0';}}],["STRSPACE",{Name:"STRSPACE",Param:{Count:1},ToString:function ToString(args){return'\u5B57\u7B26\u4E32'+args[0]+'\u52A0\u4E00\u7A7A\u683C';}}],["SUBSTR",{Name:"SUBSTR",Param:{Count:3},ToString:function ToString(args){return'\u5B57\u7B26\u4E32'+args[0]+'\u4E2D\u53D6\u4E00\u90E8\u5206';}}],["STRCMP",{Name:"STRCMP",Param:{Count:2},ToString:function ToString(args){return'\u5B57\u7B26\u4E32'+args[0]+'\u548C\u5B57\u7B26\u4E32'+args[1]+'\u6BD4\u8F83';}}],["FINDSTR",{Name:"FINDSTR",Param:{Count:2},ToString:function ToString(args){return'\u5B57\u7B26\u4E32'+args[0]+'\u4E2D\u67E5\u627E\u5B57\u7B26\u4E32'+args[1];}}],["
|
|
11419
|
+
["CON2STR",{Name:"CON2STR",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u8F6C\u4E3A\u5B57\u7B26\u4E32';}}],["VAR2STR",{Name:"VAR2STR",Param:{Count:2},ToString:function ToString(args){return args[0]+'\u8F6C\u4E3A\u5B57\u7B26\u4E32';}}],["STR2CON",{Name:"STR2CON",Param:{Count:1},ToString:function ToString(args){return args[0]+'\u8F6C\u4E3A\u6570\u5B57';}}],["STRLEN",{Name:"STRLEN",Param:{Count:1},ToString:function ToString(args){return'\u5F97\u5230'+args[0]+'\u5B57\u7B26\u4E32\u957F\u5EA6';}}],["STRCAT",{Name:"STRCAT",Param:{Count:2},ToString:function ToString(args){return'\u5B57\u7B26\u4E32\u76F8\u52A0';}}],["VARCAT",{Name:"VARCAT",Param:{Count:2},ToString:function ToString(args){return'\u5B57\u7B26\u4E32\u76F8\u52A0';}}],["STRSPACE",{Name:"STRSPACE",Param:{Count:1},ToString:function ToString(args){return'\u5B57\u7B26\u4E32'+args[0]+'\u52A0\u4E00\u7A7A\u683C';}}],["SUBSTR",{Name:"SUBSTR",Param:{Count:3},ToString:function ToString(args){return'\u5B57\u7B26\u4E32'+args[0]+'\u4E2D\u53D6\u4E00\u90E8\u5206';}}],["STRCMP",{Name:"STRCMP",Param:{Count:2},ToString:function ToString(args){return'\u5B57\u7B26\u4E32'+args[0]+'\u548C\u5B57\u7B26\u4E32'+args[1]+'\u6BD4\u8F83';}}],["FINDSTR",{Name:"FINDSTR",Param:{Count:2},ToString:function ToString(args){return'\u5B57\u7B26\u4E32'+args[0]+'\u4E2D\u67E5\u627E\u5B57\u7B26\u4E32'+args[1];}}],["NAMEINCLUDE",{Name:"NAMEINCLUDE",Param:{Count:1},ToString:function ToString(args){return'\u67E5\u627E\u54C1\u79CD\u540D\u79F0\u4E2D\u5305\u542B'+args[0];}}],["CODELIKE",{Name:"CODELIKE",Param:{Count:1},ToString:function ToString(args){return'\u67E5\u627E\u54C1\u79CD\u540D\u79F0\u4E2D\u5305\u542B'+args[0];}}],["INBLOCK",{Name:"AVEDEV",Param:{Count:1},ToString:function ToString(args){return'\u5C5E\u4E8E'+args[0]+'\u677F\u5757';}}],["STKINDI",{Name:"STKINDI",Param:{Dynamic:true},ToString:function ToString(args){return"指标引用";}}],["STRFORMAT",{Name:"STRFORMAT",Param:{Dynamic:true},ToString:function ToString(args){return'\u683C\u5F0F\u5316'+args[0]+'\u5B57\u7B26\u4E32';}}],["NAMELIKE",{Name:"NAMELIKE",Param:{Count:1},ToString:function ToString(args){return'\u54C1\u79CD\u540D\u79F0\u662F\u5426\u4EE5\''+args[0]+'\'\u5F00\u5934';}}],["HHVBARS",{Name:"HHVBARS",Param:{Count:2},ToString:function ToString(args){if(args[1]==0)return'\u5386\u53F2'+args[0]+'\u65B0\u9AD8\u8DDD\u4ECA\u5929\u6570';return args[1]+'\u65E5\u5185'+args[0]+'\u65B0\u9AD8\u8DDD\u4ECA\u5929\u6570';}}],["LLVBARS",{Name:"LLVBARS",Param:{Count:2},ToString:function ToString(args){if(args[1]==0)return'\u5386\u53F2'+args[0]+'\u65B0\u4F4E\u8DDD\u4ECA\u5929\u6570';return args[1]+'\u65E5\u5185'+args[0]+'\u65B0\u4F4E\u8DDD\u4ECA\u5929\u6570';}}]]);this.CallFunctionExplain=function(funcName,args,node){if(this.FUNCTION_INFO_LIST.has(funcName)){var item=this.FUNCTION_INFO_LIST.get(funcName);if(item.Param.Dynamic===true)//动态参数
|
|
11414
11420
|
{}else{if(item.Param.Count!=args.length)this.ThrowUnexpectedNode(node,'\u51FD\u6570'+funcName+'\u53C2\u6570\u4E2A\u6570\u4E0D\u6B63\u786E. \u9700\u8981'+item.Param.Count+'\u4E2A\u53C2\u6570');}return item.ToString(args);}switch(funcName){case"CALCSTOCKINDEX":return'\u5F15\u7528'+args[0]+'\u7684'+args[1]+'\u6307\u6807\u7B2C'+args[2]+'\u4E2A\u8F93\u51FA\u503C';case"PEAK":case"PEAKBARS":case"ZIG":case"ZIGA":case"TROUGH":case"TROUGHBARS":return this.GetZIGExplain(funcName,args);case"FINANCE":return this.GetFinanceExplain(args);case"DYNAINFO":return this.GetDynainfoExplain(args);case'CLOSE':case'C':case'VOL':case'V':case'OPEN':case'O':case'HIGH':case'H':case'LOW':case'L':case'AMOUNT':case'AMO':return this.GetOtherSymbolExplain({FunctionName:funcName,Args:args},node);//绘图函数
|
|
11415
11421
|
case"PLOYLINE":return'\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[0]+'\u65F6\u4EE5'+args[1]+'\u4F4D\u7F6E\u4E3A\u9876\u70B9\u753B\u6298\u7EBF\u8FDE\u63A5';case"DRAWLINE":return'\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[0]+'\u65F6,\u5728'+args[1]+'\u4F4D\u7F6E\u753B\u76F4\u7EBF\u8D77\u70B9\uFF0C\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[2]+'\u65F6,\u5728'+args[3]+'\u4F4D\u7F6E\u753B\u76F4\u7EBF\u7EC8\u70B9,'+args[4]+'\u8868\u793A\u662F\u5426\u5EF6\u957F';case"DRAWSL":return'\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[0]+'\u65F6,\u5728'+args[1]+'\u4F4D\u7F6E\u753B\u659C\u7EBF\u7EBF\u6027\u56DE\u5F52,'+args[2]+'\u659C\u7387,'+args[3]+'\u957F\u5EA6,'+args[4]+'\u65B9\u5411';case"DRAWKLINE":case"DRAWKLINE1":return'K线';case"DRAWICON":return'\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[0]+'\u65F6,\u5728'+args[1]+'\u4F4D\u7F6E\u753B'+args[2]+'\u53F7\u56FE\u6807';case"DRAWTEXT":return'\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[0]+'\u65F6,\u5728'+args[1]+'\u4F4D\u7F6E\u4E66\u5199\u6587\u5B57';case"DRAWTEXT_FIX":return'\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[0]+'\u65F6,\u5728\u6A2A\u8F74'+args[1]+'\u7EB5\u8F74'+args[2]+'\u4F4D\u7F6E\u4E66\u5199\u6587\u5B57';case"DRAWNUMBER":return'\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[0]+'\u65F6,\u5728'+args[1]+'\u4F4D\u7F6E\u4E66\u5199\u6570\u5B57';case"DRAWNUMBER_FIX":return'\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[0]+'\u65F6,\u5728\u6A2A\u8F74'+args[1]+'\u7EB5\u8F74'+args[2]+'\u4F4D\u7F6E\u4E66\u5199\u6570\u5B57';case"RGB":return'\u81EA\u5B9A\u8272['+args[0]+','+args[1]+','+args[2]+']';case"RGBA":return'\u81EA\u5B9A\u8272['+args[0]+','+args[1]+','+args[2]+','+args[3]+']';case"DRAWBAND":return'画带状线';case"DRAWRECTREL":return"相对位置上画矩形.";case"DRAWGBK":return"填充背景";case"TIPICON":return'\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[0]+'\u65F6,\u5728'+args[1]+'\u4F4D\u7F6E\u753B'+args[2]+'\u53F7\u56FE\u6807';case"STICKLINE":var barType="";if(args[4]==-1)barType="虚线空心柱";else if(args[4]==0)barType="实心柱";else barType="实线空心柱";return'\u5F53\u6EE1\u8DB3\u6761\u4EF6'+args[0]+'\u65F6, \u5728'+args[1]+'\u548C'+args[2]+'\u4F4D\u7F6E\u4E4B\u95F4\u753B\u67F1\u72B6\u7EBF,\u5BBD\u5EA6\u4E3A'+args[3]+','+barType;case"SELL":return"卖出平仓";case"BUY":return"买入开仓";case"SELLSHORT":return"卖出开仓";case"BUYSHORT":return"买入平仓";case"YMOVE":return;case"BACKGROUND":return"绘制背景";case"UPCOLOR":return'\u4E0A\u6DA8\u989C\u8272'+args[0];case"DOWNCOLOR":return'\u4E0B\u8DCC\u989C\u8272'+args[0];case"FIRSTDRAW":return"";default:this.ThrowUnexpectedNode(node,'\u51FD\u6570'+funcName+'\u4E0D\u5B58\u5728');}};this.GetDynainfoExplain=function(args){var DATA_NAME_MAP=new _map2.default([[3,"前收盘价"],[4,"开盘价"],[5,"最高价"],[6,"最低价"],[7,"现价"],[8,'总量'],[9,"现量"],[10,"总金额"],[11,"均价"],[12,"日涨跌"],[13,"振幅"],[14,"涨幅"],[15,"开盘时的成交金额"],[16,"前5日每分钟均量"],[17,"量比"],[18,"上涨家数"],[19,"下跌家数"]]);var id=args[0];if(DATA_NAME_MAP.has(id))return DATA_NAME_MAP.get(id);return'\u5373\u65F6\u884C\u60C5['+id+']';};this.GetFinanceExplain=function(args){var DATA_NAME_MAP=new _map2.default([[1,"总股本"],[2,"市场类型"],[3,"沪深品种类型"],[4,"沪深行业代码"],[5,"B股"],[6,"H股"],[7,"流通股本[股]"],[8,"股东人数[户]"],[9,"资产负债率%"],[10,"总资产"],[11,"流动资产"],[12,"固定资产"],[13,"无形资产"],[15,"流动负债"],[16,"少数股东权益"]]);var id=args[0];if(DATA_NAME_MAP.has(id))return DATA_NAME_MAP.get(id);return'\u8D22\u52A1\u6570\u636E['+id+']';};this.GetZIGExplain=function(funcName,args){var value=args[0];if(value==0)value="开盘价";else if(value==1)value="最高价";else if(value==2)value="最低价";else if(value==3)value="收盘价";switch(funcName){case"PEAK":return value+'\u7684'+args[1]+'%\u4E4B\u5B57\u8F6C\u5411\u7684\u524D'+args[2]+'\u4E2A\u6CE2\u5CF0\u503C';case"PEAKBARS":return value+'\u7684'+args[1]+'5%\u4E4B\u5B57\u8F6C\u5411\u7684\u524D'+args[2]+'\u4E2A\u6CE2\u5CF0\u4F4D\u7F6E';case"ZIG":return value+'\u7684'+args[1]+'\u7684\u4E4B\u5B57\u8F6C\u5411';case"ZIGA":return value+'\u53D8\u5316'+args[1]+'\u7684\u4E4B\u5B57\u8F6C\u5411';case"TROUGH":return value+'\u7684'+args[1]+'%\u4E4B\u5B57\u8F6C\u5411\u7684\u524D'+args[2]+'\u4E2A\u6CE2\u8C37\u503C';case"TROUGHBARS":return value+'\u7684'+args[1]+'%\u4E4B\u5B57\u8F6C\u5411\u7684\u524D'+args[2]+'\u4E2A\u6CE2\u8C37\u4F4D\u7F6E';}};this.GetColorExplain=function(colorName){var COLOR_MAP=new _map2.default([['COLORBLACK','黑色'],['COLORBLUE','蓝色'],['COLORGREEN','绿色'],['COLORCYAN','青色'],['COLORRED','红色'],['COLORMAGENTA','洋红色'],['COLORBROWN','棕色'],['COLORLIGRAY','淡灰色'],['COLORGRAY','深灰色'],['COLORLIBLUE','淡蓝色'],['COLORLIGREEN','淡绿色'],['COLORLICYAN','淡青色'],['COLORLIRED','淡红色'],['COLORLIMAGENTA','淡洋红色'],['COLORWHITE','白色'],['COLORYELLOW','黄色']]);if(COLOR_MAP.has(colorName))return COLOR_MAP.get(colorName);//COLOR 自定义色
|
|
11416
11422
|
//格式为COLOR+“RRGGBB”:RR、GG、BB表示红色、绿色和蓝色的分量,每种颜色的取值范围是00-FF,采用了16进制。
|
|
@@ -12895,7 +12901,7 @@ hisData.Symbol=message.symbol;}var stockObj={HQDataType:HQ_DATA_TYPE.KLINE_ID,St
|
|
|
12895
12901
|
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);};}/********************************************************************************
|
|
12896
12902
|
* 版本信息输出
|
|
12897
12903
|
*
|
|
12898
|
-
*/var HQCHART_VERSION="1.1.
|
|
12904
|
+
*/var HQCHART_VERSION="1.1.12728";function PrintHQChartVersion(){var log='*************************************************************************************************************\n*\n* HQChart Ver: '+HQCHART_VERSION+' \n* \n* License: Apache License 2.0 \n* Source: https://github.com/jones2000/HQChart\n*\n*************************************************************************************************************\n';console.log(log);}PrintHQChartVersion();//把给外界调用的方法暴露出来
|
|
12899
12905
|
exports.default=(_jsChartInit$jsChartS={jsChartInit:JSChart.Init,jsChartStyle:JSChart.SetStyle,// IsIndexSymbol:IsIndexSymbol,
|
|
12900
12906
|
// BaseIndex:BaseIndex,
|
|
12901
12907
|
// ChartLine:ChartLine,
|
package/package.json
CHANGED
|
@@ -13399,6 +13399,7 @@ function IChartFramePainting()
|
|
|
13399
13399
|
|
|
13400
13400
|
//this.IsDrawLeftBorder;
|
|
13401
13401
|
this.IsDrawRightBorder=false; //是否绘制右侧刻度空白的边框
|
|
13402
|
+
this.IsDrawLeftBorder=false; //是否绘制右侧刻度空白的边框
|
|
13402
13403
|
|
|
13403
13404
|
this.PtInButtons=function(x,y) //坐标是否在按钮上
|
|
13404
13405
|
{
|
|
@@ -13499,16 +13500,42 @@ function IChartFramePainting()
|
|
|
13499
13500
|
//JSConsole.Chart.Log(`[IChartFramePainting.DrawBorder] left=${left} `);
|
|
13500
13501
|
if (this.BorderLine==null)
|
|
13501
13502
|
{
|
|
13502
|
-
if (this.IsDrawRightBorder)
|
|
13503
|
+
if (this.IsDrawRightBorder || this.IsDrawLeftBorder)
|
|
13503
13504
|
{
|
|
13504
|
-
var xRight=ToFixedPoint(border.ChartWidth);
|
|
13505
13505
|
this.Canvas.strokeStyle=this.PenBorder;
|
|
13506
|
-
this.Canvas.strokeRect(left,top,xRight-left,height);
|
|
13507
13506
|
|
|
13508
|
-
this.
|
|
13509
|
-
|
|
13510
|
-
|
|
13511
|
-
|
|
13507
|
+
if (this.IsDrawRightBorder && this.IsDrawLeftBorder)
|
|
13508
|
+
{
|
|
13509
|
+
var xRight=ToFixedPoint(border.ChartWidth);
|
|
13510
|
+
var xLeft=ToFixedPoint(0);
|
|
13511
|
+
this.Canvas.strokeRect(xLeft,top,xRight-xLeft-1,height); //少一个像素让边框显示出来
|
|
13512
|
+
}
|
|
13513
|
+
else if (this.IsDrawRightBorder)
|
|
13514
|
+
{
|
|
13515
|
+
var xRight=ToFixedPoint(border.ChartWidth);
|
|
13516
|
+
this.Canvas.strokeRect(left,top,xRight-left-1,height); //少一个像素让边框显示出来
|
|
13517
|
+
}
|
|
13518
|
+
else if (this.IsDrawLeftBorder)
|
|
13519
|
+
{
|
|
13520
|
+
var xLeft=ToFixedPoint(0);
|
|
13521
|
+
this.Canvas.strokeRect(xLeft,top,right-xLeft,height); //少一个像素让边框显示出来
|
|
13522
|
+
}
|
|
13523
|
+
|
|
13524
|
+
if (this.IsDrawRightBorder)
|
|
13525
|
+
{
|
|
13526
|
+
this.Canvas.beginPath();
|
|
13527
|
+
this.Canvas.moveTo(right,top);
|
|
13528
|
+
this.Canvas.lineTo(right,bottom);
|
|
13529
|
+
this.Canvas.stroke();
|
|
13530
|
+
}
|
|
13531
|
+
|
|
13532
|
+
if (this.IsDrawLeftBorder)
|
|
13533
|
+
{
|
|
13534
|
+
this.Canvas.beginPath();
|
|
13535
|
+
this.Canvas.moveTo(left,top);
|
|
13536
|
+
this.Canvas.lineTo(left,bottom);
|
|
13537
|
+
this.Canvas.stroke();
|
|
13538
|
+
}
|
|
13512
13539
|
}
|
|
13513
13540
|
else
|
|
13514
13541
|
{
|
|
@@ -14050,14 +14077,18 @@ function AverageWidthFrame()
|
|
|
14050
14077
|
var isDrawRight=borderRight>10 && this.IsShowYText[1]===true && this.YTextPosition[1]!=2;
|
|
14051
14078
|
|
|
14052
14079
|
var rightExtendLine=null; //右侧延长线
|
|
14080
|
+
var leftExtendLine=null; //左侧延长线
|
|
14053
14081
|
if (IFrameSplitOperator.IsNonEmptyArray(this.YLineExtend))
|
|
14054
14082
|
{
|
|
14055
14083
|
rightExtendLine=this.YLineExtend[1];
|
|
14084
|
+
leftExtendLine=this.YLineExtend[0];
|
|
14056
14085
|
}
|
|
14057
14086
|
|
|
14058
14087
|
var rightExtendText=null; //右侧文字设置
|
|
14088
|
+
var leftExtendText=null; //左侧文字设置
|
|
14059
14089
|
if (IFrameSplitOperator.IsNonEmptyArray(this.YTextExtend))
|
|
14060
14090
|
{
|
|
14091
|
+
leftExtendText=this.YTextExtend[0];
|
|
14061
14092
|
rightExtendText=this.YTextExtend[1];
|
|
14062
14093
|
}
|
|
14063
14094
|
|
|
@@ -14159,12 +14190,34 @@ function AverageWidthFrame()
|
|
|
14159
14190
|
{
|
|
14160
14191
|
if (item.Font!=null) this.Canvas.font=item.Font;
|
|
14161
14192
|
|
|
14193
|
+
var xText=left;
|
|
14194
|
+
if (leftExtendLine && leftExtendLine.Width>1)
|
|
14195
|
+
{
|
|
14196
|
+
var lineLength=leftExtendLine.Width;
|
|
14197
|
+
if (leftExtendLine.Color) this.Canvas.strokeStyle=leftExtendLine.Color;
|
|
14198
|
+
else this.Canvas.strokeStyle=item.LineColor;
|
|
14199
|
+
this.Canvas.beginPath();
|
|
14200
|
+
this.Canvas.moveTo(xText,yFixed);
|
|
14201
|
+
this.Canvas.lineTo(xText-lineLength,yFixed);
|
|
14202
|
+
this.Canvas.stroke();
|
|
14203
|
+
|
|
14204
|
+
xText-=lineLength;
|
|
14205
|
+
}
|
|
14206
|
+
|
|
14162
14207
|
rtLeft=this.GetTextTopBottom(textBaseline,yText);
|
|
14163
14208
|
if (!rtPreLeft || (rtLeft && !this.IsTextTopBottomOverlap(rtLeft, rtPreLeft)))
|
|
14164
14209
|
{
|
|
14165
|
-
|
|
14166
|
-
|
|
14167
|
-
|
|
14210
|
+
if (leftExtendText && leftExtendText.Align===1)
|
|
14211
|
+
{
|
|
14212
|
+
this.Canvas.textAlign="left";
|
|
14213
|
+
this.Canvas.fillText(item.Message[0],this.YTextPadding[0],yText);
|
|
14214
|
+
}
|
|
14215
|
+
else
|
|
14216
|
+
{
|
|
14217
|
+
this.Canvas.textAlign="right";
|
|
14218
|
+
this.Canvas.fillText(item.Message[0],xText-this.YTextPadding[0],yText);
|
|
14219
|
+
rtPreLeft=rtLeft;
|
|
14220
|
+
}
|
|
14168
14221
|
}
|
|
14169
14222
|
}
|
|
14170
14223
|
|
|
@@ -14242,7 +14295,7 @@ function AverageWidthFrame()
|
|
|
14242
14295
|
if (!rtPreRight || (rtRight && !this.IsTextTopBottomOverlap(rtRight,rtPreRight)))
|
|
14243
14296
|
{
|
|
14244
14297
|
if (item.TextColor2) this.Canvas.fillStyle=item.TextColor2;
|
|
14245
|
-
if (rightExtendText && rightExtendText.Align && this.YRightTextInfo)
|
|
14298
|
+
if (rightExtendText && rightExtendText.Align===2 && this.YRightTextInfo)
|
|
14246
14299
|
{
|
|
14247
14300
|
this.Canvas.textAlign="right";
|
|
14248
14301
|
var xRight=this.YRightTextInfo.MainTextWidth+right-this.YTextPadding[1];
|
|
@@ -15468,6 +15521,16 @@ function AverageWidthFrame()
|
|
|
15468
15521
|
var rightExtendWidth=0;
|
|
15469
15522
|
var isYPercentage=false; //是否是百分比坐标
|
|
15470
15523
|
if (this.YSplitOperator && this.YSplitOperator.CoordinateType==1) isYPercentage=true;
|
|
15524
|
+
|
|
15525
|
+
var leftExtendLineWidth=0;
|
|
15526
|
+
var rightExtendLineWidth=0;
|
|
15527
|
+
if (IFrameSplitOperator.IsNonEmptyArray(this.YLineExtend))
|
|
15528
|
+
{
|
|
15529
|
+
if (this.YLineExtend[0] && this.YLineExtend[0].Width>1)
|
|
15530
|
+
leftExtendLineWidth=this.YLineExtend[0].Width;
|
|
15531
|
+
if (this.YLineExtend[1] && this.YLineExtend[1].Width>1)
|
|
15532
|
+
rightExtendLineWidth=this.YLineExtend[1].Width;
|
|
15533
|
+
}
|
|
15471
15534
|
|
|
15472
15535
|
for(var i=0;i<this.HorizontalInfo.length;++i)
|
|
15473
15536
|
{
|
|
@@ -15534,8 +15597,8 @@ function AverageWidthFrame()
|
|
|
15534
15597
|
|
|
15535
15598
|
|
|
15536
15599
|
if (IFrameSplitOperator.IsNumber(width.Right)) width.Right+=rightExtendWidth;
|
|
15537
|
-
if (IFrameSplitOperator.IsNumber(width.Left)) width.Left+=this.YTextPadding[0];
|
|
15538
|
-
if (IFrameSplitOperator.IsNumber(width.Right)) width.Right+=this.YTextPadding[1];
|
|
15600
|
+
if (IFrameSplitOperator.IsNumber(width.Left)) width.Left+=this.YTextPadding[0]+leftExtendLineWidth;
|
|
15601
|
+
if (IFrameSplitOperator.IsNumber(width.Right)) width.Right+=this.YTextPadding[1]+rightExtendLineWidth;
|
|
15539
15602
|
|
|
15540
15603
|
return { TextWidth:width };
|
|
15541
15604
|
}
|
|
@@ -113342,12 +113405,12 @@ function JSExplainer(ast,option)
|
|
|
113342
113405
|
["SUBSTR", { Name:"SUBSTR", Param:{ Count:3 }, ToString:function(args) { return `字符串${args[0]}中取一部分`; } } ],
|
|
113343
113406
|
["STRCMP", { Name:"STRCMP", Param:{ Count:2 }, ToString:function(args) { return `字符串${args[0]}和字符串${args[1]}比较`; } } ],
|
|
113344
113407
|
["FINDSTR", { Name:"FINDSTR", Param:{ Count:2 }, ToString:function(args) { return `字符串${args[0]}中查找字符串${args[1]}`; } } ],
|
|
113345
|
-
["
|
|
113408
|
+
["NAMEINCLUDE", { Name:"NAMEINCLUDE", Param:{ Count:1 }, ToString:function(args) { return `查找品种名称中包含${args[0]}`; } } ],
|
|
113346
113409
|
["CODELIKE", { Name:"CODELIKE", Param:{ Count:1 }, ToString:function(args) { return `查找品种名称中包含${args[0]}`; } } ],
|
|
113347
113410
|
["INBLOCK", { Name:"AVEDEV", Param:{ Count:1 }, ToString:function(args) { return `属于${args[0]}板块`; } } ],
|
|
113348
113411
|
["STKINDI",{ Name:"STKINDI", Param:{ Dynamic:true }, ToString:function(args) { return "指标引用"; } }],
|
|
113349
113412
|
["STRFORMAT",{ Name:"STRFORMAT", Param:{ Dynamic:true }, ToString:function(args) { return `格式化${args[0]}字符串`; } }],
|
|
113350
|
-
|
|
113413
|
+
["NAMELIKE",{ Name:"NAMELIKE", Param:{ Count:1 }, ToString:function(args) { return `品种名称是否以'${args[0]}'开头`; } }],
|
|
113351
113414
|
|
|
113352
113415
|
[
|
|
113353
113416
|
"HHVBARS",
|
|
@@ -113490,6 +113553,7 @@ function JSExplainer(ast,option)
|
|
|
113490
113553
|
case "FIRSTDRAW":
|
|
113491
113554
|
return "";
|
|
113492
113555
|
|
|
113556
|
+
|
|
113493
113557
|
default:
|
|
113494
113558
|
this.ThrowUnexpectedNode(node,`函数${funcName}不存在`);
|
|
113495
113559
|
}
|
|
@@ -130969,7 +131033,7 @@ function ScrollBarBGChart()
|
|
|
130969
131033
|
|
|
130970
131034
|
|
|
130971
131035
|
|
|
130972
|
-
var HQCHART_VERSION="1.1.
|
|
131036
|
+
var HQCHART_VERSION="1.1.12728";
|
|
130973
131037
|
|
|
130974
131038
|
function PrintHQChartVersion()
|
|
130975
131039
|
{
|
|
@@ -13443,6 +13443,7 @@ function IChartFramePainting()
|
|
|
13443
13443
|
|
|
13444
13444
|
//this.IsDrawLeftBorder;
|
|
13445
13445
|
this.IsDrawRightBorder=false; //是否绘制右侧刻度空白的边框
|
|
13446
|
+
this.IsDrawLeftBorder=false; //是否绘制右侧刻度空白的边框
|
|
13446
13447
|
|
|
13447
13448
|
this.PtInButtons=function(x,y) //坐标是否在按钮上
|
|
13448
13449
|
{
|
|
@@ -13543,16 +13544,42 @@ function IChartFramePainting()
|
|
|
13543
13544
|
//JSConsole.Chart.Log(`[IChartFramePainting.DrawBorder] left=${left} `);
|
|
13544
13545
|
if (this.BorderLine==null)
|
|
13545
13546
|
{
|
|
13546
|
-
if (this.IsDrawRightBorder)
|
|
13547
|
+
if (this.IsDrawRightBorder || this.IsDrawLeftBorder)
|
|
13547
13548
|
{
|
|
13548
|
-
var xRight=ToFixedPoint(border.ChartWidth);
|
|
13549
13549
|
this.Canvas.strokeStyle=this.PenBorder;
|
|
13550
|
-
this.Canvas.strokeRect(left,top,xRight-left,height);
|
|
13551
13550
|
|
|
13552
|
-
this.
|
|
13553
|
-
|
|
13554
|
-
|
|
13555
|
-
|
|
13551
|
+
if (this.IsDrawRightBorder && this.IsDrawLeftBorder)
|
|
13552
|
+
{
|
|
13553
|
+
var xRight=ToFixedPoint(border.ChartWidth);
|
|
13554
|
+
var xLeft=ToFixedPoint(0);
|
|
13555
|
+
this.Canvas.strokeRect(xLeft,top,xRight-xLeft-1,height); //少一个像素让边框显示出来
|
|
13556
|
+
}
|
|
13557
|
+
else if (this.IsDrawRightBorder)
|
|
13558
|
+
{
|
|
13559
|
+
var xRight=ToFixedPoint(border.ChartWidth);
|
|
13560
|
+
this.Canvas.strokeRect(left,top,xRight-left-1,height); //少一个像素让边框显示出来
|
|
13561
|
+
}
|
|
13562
|
+
else if (this.IsDrawLeftBorder)
|
|
13563
|
+
{
|
|
13564
|
+
var xLeft=ToFixedPoint(0);
|
|
13565
|
+
this.Canvas.strokeRect(xLeft,top,right-xLeft,height); //少一个像素让边框显示出来
|
|
13566
|
+
}
|
|
13567
|
+
|
|
13568
|
+
if (this.IsDrawRightBorder)
|
|
13569
|
+
{
|
|
13570
|
+
this.Canvas.beginPath();
|
|
13571
|
+
this.Canvas.moveTo(right,top);
|
|
13572
|
+
this.Canvas.lineTo(right,bottom);
|
|
13573
|
+
this.Canvas.stroke();
|
|
13574
|
+
}
|
|
13575
|
+
|
|
13576
|
+
if (this.IsDrawLeftBorder)
|
|
13577
|
+
{
|
|
13578
|
+
this.Canvas.beginPath();
|
|
13579
|
+
this.Canvas.moveTo(left,top);
|
|
13580
|
+
this.Canvas.lineTo(left,bottom);
|
|
13581
|
+
this.Canvas.stroke();
|
|
13582
|
+
}
|
|
13556
13583
|
}
|
|
13557
13584
|
else
|
|
13558
13585
|
{
|
|
@@ -14094,14 +14121,18 @@ function AverageWidthFrame()
|
|
|
14094
14121
|
var isDrawRight=borderRight>10 && this.IsShowYText[1]===true && this.YTextPosition[1]!=2;
|
|
14095
14122
|
|
|
14096
14123
|
var rightExtendLine=null; //右侧延长线
|
|
14124
|
+
var leftExtendLine=null; //左侧延长线
|
|
14097
14125
|
if (IFrameSplitOperator.IsNonEmptyArray(this.YLineExtend))
|
|
14098
14126
|
{
|
|
14099
14127
|
rightExtendLine=this.YLineExtend[1];
|
|
14128
|
+
leftExtendLine=this.YLineExtend[0];
|
|
14100
14129
|
}
|
|
14101
14130
|
|
|
14102
14131
|
var rightExtendText=null; //右侧文字设置
|
|
14132
|
+
var leftExtendText=null; //左侧文字设置
|
|
14103
14133
|
if (IFrameSplitOperator.IsNonEmptyArray(this.YTextExtend))
|
|
14104
14134
|
{
|
|
14135
|
+
leftExtendText=this.YTextExtend[0];
|
|
14105
14136
|
rightExtendText=this.YTextExtend[1];
|
|
14106
14137
|
}
|
|
14107
14138
|
|
|
@@ -14203,12 +14234,34 @@ function AverageWidthFrame()
|
|
|
14203
14234
|
{
|
|
14204
14235
|
if (item.Font!=null) this.Canvas.font=item.Font;
|
|
14205
14236
|
|
|
14237
|
+
var xText=left;
|
|
14238
|
+
if (leftExtendLine && leftExtendLine.Width>1)
|
|
14239
|
+
{
|
|
14240
|
+
var lineLength=leftExtendLine.Width;
|
|
14241
|
+
if (leftExtendLine.Color) this.Canvas.strokeStyle=leftExtendLine.Color;
|
|
14242
|
+
else this.Canvas.strokeStyle=item.LineColor;
|
|
14243
|
+
this.Canvas.beginPath();
|
|
14244
|
+
this.Canvas.moveTo(xText,yFixed);
|
|
14245
|
+
this.Canvas.lineTo(xText-lineLength,yFixed);
|
|
14246
|
+
this.Canvas.stroke();
|
|
14247
|
+
|
|
14248
|
+
xText-=lineLength;
|
|
14249
|
+
}
|
|
14250
|
+
|
|
14206
14251
|
rtLeft=this.GetTextTopBottom(textBaseline,yText);
|
|
14207
14252
|
if (!rtPreLeft || (rtLeft && !this.IsTextTopBottomOverlap(rtLeft, rtPreLeft)))
|
|
14208
14253
|
{
|
|
14209
|
-
|
|
14210
|
-
|
|
14211
|
-
|
|
14254
|
+
if (leftExtendText && leftExtendText.Align===1)
|
|
14255
|
+
{
|
|
14256
|
+
this.Canvas.textAlign="left";
|
|
14257
|
+
this.Canvas.fillText(item.Message[0],this.YTextPadding[0],yText);
|
|
14258
|
+
}
|
|
14259
|
+
else
|
|
14260
|
+
{
|
|
14261
|
+
this.Canvas.textAlign="right";
|
|
14262
|
+
this.Canvas.fillText(item.Message[0],xText-this.YTextPadding[0],yText);
|
|
14263
|
+
rtPreLeft=rtLeft;
|
|
14264
|
+
}
|
|
14212
14265
|
}
|
|
14213
14266
|
}
|
|
14214
14267
|
|
|
@@ -14286,7 +14339,7 @@ function AverageWidthFrame()
|
|
|
14286
14339
|
if (!rtPreRight || (rtRight && !this.IsTextTopBottomOverlap(rtRight,rtPreRight)))
|
|
14287
14340
|
{
|
|
14288
14341
|
if (item.TextColor2) this.Canvas.fillStyle=item.TextColor2;
|
|
14289
|
-
if (rightExtendText && rightExtendText.Align && this.YRightTextInfo)
|
|
14342
|
+
if (rightExtendText && rightExtendText.Align===2 && this.YRightTextInfo)
|
|
14290
14343
|
{
|
|
14291
14344
|
this.Canvas.textAlign="right";
|
|
14292
14345
|
var xRight=this.YRightTextInfo.MainTextWidth+right-this.YTextPadding[1];
|
|
@@ -15512,6 +15565,16 @@ function AverageWidthFrame()
|
|
|
15512
15565
|
var rightExtendWidth=0;
|
|
15513
15566
|
var isYPercentage=false; //是否是百分比坐标
|
|
15514
15567
|
if (this.YSplitOperator && this.YSplitOperator.CoordinateType==1) isYPercentage=true;
|
|
15568
|
+
|
|
15569
|
+
var leftExtendLineWidth=0;
|
|
15570
|
+
var rightExtendLineWidth=0;
|
|
15571
|
+
if (IFrameSplitOperator.IsNonEmptyArray(this.YLineExtend))
|
|
15572
|
+
{
|
|
15573
|
+
if (this.YLineExtend[0] && this.YLineExtend[0].Width>1)
|
|
15574
|
+
leftExtendLineWidth=this.YLineExtend[0].Width;
|
|
15575
|
+
if (this.YLineExtend[1] && this.YLineExtend[1].Width>1)
|
|
15576
|
+
rightExtendLineWidth=this.YLineExtend[1].Width;
|
|
15577
|
+
}
|
|
15515
15578
|
|
|
15516
15579
|
for(var i=0;i<this.HorizontalInfo.length;++i)
|
|
15517
15580
|
{
|
|
@@ -15578,8 +15641,8 @@ function AverageWidthFrame()
|
|
|
15578
15641
|
|
|
15579
15642
|
|
|
15580
15643
|
if (IFrameSplitOperator.IsNumber(width.Right)) width.Right+=rightExtendWidth;
|
|
15581
|
-
if (IFrameSplitOperator.IsNumber(width.Left)) width.Left+=this.YTextPadding[0];
|
|
15582
|
-
if (IFrameSplitOperator.IsNumber(width.Right)) width.Right+=this.YTextPadding[1];
|
|
15644
|
+
if (IFrameSplitOperator.IsNumber(width.Left)) width.Left+=this.YTextPadding[0]+leftExtendLineWidth;
|
|
15645
|
+
if (IFrameSplitOperator.IsNumber(width.Right)) width.Right+=this.YTextPadding[1]+rightExtendLineWidth;
|
|
15583
15646
|
|
|
15584
15647
|
return { TextWidth:width };
|
|
15585
15648
|
}
|
|
@@ -113386,12 +113449,12 @@ function JSExplainer(ast,option)
|
|
|
113386
113449
|
["SUBSTR", { Name:"SUBSTR", Param:{ Count:3 }, ToString:function(args) { return `字符串${args[0]}中取一部分`; } } ],
|
|
113387
113450
|
["STRCMP", { Name:"STRCMP", Param:{ Count:2 }, ToString:function(args) { return `字符串${args[0]}和字符串${args[1]}比较`; } } ],
|
|
113388
113451
|
["FINDSTR", { Name:"FINDSTR", Param:{ Count:2 }, ToString:function(args) { return `字符串${args[0]}中查找字符串${args[1]}`; } } ],
|
|
113389
|
-
["
|
|
113452
|
+
["NAMEINCLUDE", { Name:"NAMEINCLUDE", Param:{ Count:1 }, ToString:function(args) { return `查找品种名称中包含${args[0]}`; } } ],
|
|
113390
113453
|
["CODELIKE", { Name:"CODELIKE", Param:{ Count:1 }, ToString:function(args) { return `查找品种名称中包含${args[0]}`; } } ],
|
|
113391
113454
|
["INBLOCK", { Name:"AVEDEV", Param:{ Count:1 }, ToString:function(args) { return `属于${args[0]}板块`; } } ],
|
|
113392
113455
|
["STKINDI",{ Name:"STKINDI", Param:{ Dynamic:true }, ToString:function(args) { return "指标引用"; } }],
|
|
113393
113456
|
["STRFORMAT",{ Name:"STRFORMAT", Param:{ Dynamic:true }, ToString:function(args) { return `格式化${args[0]}字符串`; } }],
|
|
113394
|
-
|
|
113457
|
+
["NAMELIKE",{ Name:"NAMELIKE", Param:{ Count:1 }, ToString:function(args) { return `品种名称是否以'${args[0]}'开头`; } }],
|
|
113395
113458
|
|
|
113396
113459
|
[
|
|
113397
113460
|
"HHVBARS",
|
|
@@ -113534,6 +113597,7 @@ function JSExplainer(ast,option)
|
|
|
113534
113597
|
case "FIRSTDRAW":
|
|
113535
113598
|
return "";
|
|
113536
113599
|
|
|
113600
|
+
|
|
113537
113601
|
default:
|
|
113538
113602
|
this.ThrowUnexpectedNode(node,`函数${funcName}不存在`);
|
|
113539
113603
|
}
|
|
@@ -131127,7 +131191,7 @@ function HQChartScriptWorker()
|
|
|
131127
131191
|
|
|
131128
131192
|
|
|
131129
131193
|
|
|
131130
|
-
var HQCHART_VERSION="1.1.
|
|
131194
|
+
var HQCHART_VERSION="1.1.12728";
|
|
131131
131195
|
|
|
131132
131196
|
function PrintHQChartVersion()
|
|
131133
131197
|
{
|