hqchart 1.1.13614 → 1.1.13623
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/src/jscommon/umychart.js
CHANGED
|
@@ -2613,6 +2613,7 @@ var JSCHART_EVENT_ID=
|
|
|
2613
2613
|
ON_FORMAT_CALL_AUCTION_INDEX_TITLE:153, //集合竞价指标窗口标题内容
|
|
2614
2614
|
|
|
2615
2615
|
ON_FORMAT_KLINE_HIGH_LOW_TITLE:154, //K线最高最低价格式化内容
|
|
2616
|
+
ON_CUSTOM_CORSSCURSOR_POSITION:155, //自定义十字光标X轴的输出的位置
|
|
2616
2617
|
}
|
|
2617
2618
|
|
|
2618
2619
|
var JSCHART_OPERATOR_ID=
|
|
@@ -10300,7 +10301,7 @@ function IChartFramePainting()
|
|
|
10300
10301
|
|
|
10301
10302
|
this.YSpecificMaxMin=null; //指定Y轴最大最小值
|
|
10302
10303
|
this.IsShowBorder = true; //是否显示边框
|
|
10303
|
-
this.IsShowTitleArrow=
|
|
10304
|
+
this.IsShowTitleArrow=g_JSChartResource.IndexTitle.EnableIndexArrow; //是否显示指标信息上涨下跌箭头
|
|
10304
10305
|
this.TitleArrowType=g_JSChartResource.IndexTitle.ArrowType; //指标信息上涨下跌箭头类型 0=独立颜色 1=跟指标名字颜色一致
|
|
10305
10306
|
this.IsShowIndexName=true; //是否显示指标名字
|
|
10306
10307
|
this.IsShowOverlayIndexName=true; //是否显示叠加指标名字
|
|
@@ -49740,8 +49741,8 @@ function ChartCorssCursor()
|
|
|
49740
49741
|
}
|
|
49741
49742
|
}
|
|
49742
49743
|
|
|
49743
|
-
//X轴 Bottom
|
|
49744
|
-
if ((this.ShowTextMode.Bottom==1 || this.ShowTextMode.Bottom==2 || this.ShowTextMode.Bottom==
|
|
49744
|
+
//X轴 Bottom==8 自定义
|
|
49745
|
+
if ((this.ShowTextMode.Bottom==1 || this.ShowTextMode.Bottom==2 || this.ShowTextMode.Bottom==8) && this.StringFormatX.Operator())
|
|
49745
49746
|
{
|
|
49746
49747
|
var text=this.StringFormatX.Text;
|
|
49747
49748
|
this.Canvas.font=this.Font;
|
|
@@ -49750,49 +49751,53 @@ function ChartCorssCursor()
|
|
|
49750
49751
|
|
|
49751
49752
|
var yCenter=bottom+2+this.TextHeight/2;
|
|
49752
49753
|
var yTop=bottom+2;
|
|
49754
|
+
var bShowText=true;
|
|
49753
49755
|
if (this.ShowTextMode.Bottom==2)
|
|
49754
49756
|
{
|
|
49755
49757
|
yCenter=bottom-this.TextHeight/2-2;
|
|
49756
49758
|
yTop=bottom-this.TextHeight-2;
|
|
49757
49759
|
}
|
|
49758
|
-
else if (this.ShowTextMode.Bottom==
|
|
49760
|
+
else if (this.ShowTextMode.Bottom==8)
|
|
49759
49761
|
{
|
|
49760
|
-
var
|
|
49761
|
-
if (
|
|
49762
|
+
var event=this.GetEventCallback(JSCHART_EVENT_ID.ON_CUSTOM_CORSSCURSOR_POSITION);
|
|
49763
|
+
if (event && event.Callback)
|
|
49762
49764
|
{
|
|
49763
|
-
var
|
|
49764
|
-
|
|
49765
|
-
|
|
49766
|
-
|
|
49767
|
-
|
|
49768
|
-
|
|
49765
|
+
var sendData={ YCenter:yCenter, YTop:yTop, Height:this.TextHeight, IsShowText:bShowText };
|
|
49766
|
+
event.Callback(event, sendData, this);
|
|
49767
|
+
|
|
49768
|
+
yCenter=sendData.YCenter;
|
|
49769
|
+
yTop=sendData.YTop;
|
|
49770
|
+
bShowText=sendData.IsShowText;
|
|
49769
49771
|
}
|
|
49770
49772
|
}
|
|
49771
49773
|
|
|
49772
49774
|
//JSConsole.Chart.Log('[ChartCorssCursor::Draw] ',yCenter);
|
|
49773
|
-
if (
|
|
49775
|
+
if (bShowText)
|
|
49774
49776
|
{
|
|
49775
|
-
|
|
49776
|
-
|
|
49777
|
-
|
|
49778
|
-
|
|
49779
|
-
|
|
49780
|
-
|
|
49781
|
-
|
|
49782
|
-
|
|
49783
|
-
|
|
49784
|
-
|
|
49785
|
-
|
|
49786
|
-
|
|
49787
|
-
|
|
49788
|
-
|
|
49789
|
-
|
|
49790
|
-
|
|
49791
|
-
|
|
49792
|
-
|
|
49793
|
-
|
|
49794
|
-
|
|
49795
|
-
|
|
49777
|
+
if (x-textWidth/2<3) //左边位置不够了, 顶着左边画
|
|
49778
|
+
{
|
|
49779
|
+
this.DrawTextBGRect(x-1,yTop,textWidth,this.TextHeight);
|
|
49780
|
+
this.Canvas.textAlign="left";
|
|
49781
|
+
this.Canvas.textBaseline="middle";
|
|
49782
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
49783
|
+
this.Canvas.fillText(text,x+1,yCenter,textWidth);
|
|
49784
|
+
}
|
|
49785
|
+
else if (x+textWidth/2>=right)
|
|
49786
|
+
{
|
|
49787
|
+
this.DrawTextBGRect(right-textWidth,yTop,textWidth,this.TextHeight);
|
|
49788
|
+
this.Canvas.textAlign="right";
|
|
49789
|
+
this.Canvas.textBaseline="middle";
|
|
49790
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
49791
|
+
this.Canvas.fillText(text,right-2,yCenter,textWidth);
|
|
49792
|
+
}
|
|
49793
|
+
else
|
|
49794
|
+
{
|
|
49795
|
+
this.DrawTextBGRect(x-textWidth/2,yTop,textWidth,this.TextHeight);
|
|
49796
|
+
this.Canvas.textAlign="center";
|
|
49797
|
+
this.Canvas.textBaseline="middle";
|
|
49798
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
49799
|
+
this.Canvas.fillText(text,x,yCenter,textWidth);
|
|
49800
|
+
}
|
|
49796
49801
|
}
|
|
49797
49802
|
}
|
|
49798
49803
|
|
|
@@ -50296,7 +50301,7 @@ function ChartCorssCursor()
|
|
|
50296
50301
|
}
|
|
50297
50302
|
|
|
50298
50303
|
//X轴 Bottom=10 使用第1个指标框位置
|
|
50299
|
-
if ((this.ShowTextMode.Bottom===1 || this.ShowTextMode.Bottom==
|
|
50304
|
+
if ((this.ShowTextMode.Bottom===1 || this.ShowTextMode.Bottom==8) && this.StringFormatX.Operator())
|
|
50300
50305
|
{
|
|
50301
50306
|
var text=this.StringFormatX.Text;
|
|
50302
50307
|
this.Canvas.font=this.Font;
|
|
@@ -50304,64 +50309,67 @@ function ChartCorssCursor()
|
|
|
50304
50309
|
this.Canvas.fillStyle=this.TextBGColor;
|
|
50305
50310
|
var textWidth=this.Canvas.measureText(text).width+4; //前后各空2个像素
|
|
50306
50311
|
var xText=left;
|
|
50307
|
-
|
|
50308
|
-
if (this.ShowTextMode.Bottom==
|
|
50312
|
+
var bShowText=true;
|
|
50313
|
+
if (this.ShowTextMode.Bottom==8)
|
|
50309
50314
|
{
|
|
50310
|
-
var
|
|
50311
|
-
if (
|
|
50315
|
+
var event=this.GetEventCallback(JSCHART_EVENT_ID.ON_CUSTOM_CORSSCURSOR_POSITION);
|
|
50316
|
+
if (event && event.Callback)
|
|
50312
50317
|
{
|
|
50313
|
-
var
|
|
50314
|
-
|
|
50315
|
-
|
|
50316
|
-
|
|
50317
|
-
|
|
50318
|
+
var sendData={ XText:xText, Height:this.TextHeight, IsShowText:bShowText };
|
|
50319
|
+
event.Callback(event, sendData, this);
|
|
50320
|
+
|
|
50321
|
+
xText=sendData.XText;
|
|
50322
|
+
bShowText=sendData.IsShowText;
|
|
50318
50323
|
}
|
|
50319
50324
|
}
|
|
50320
50325
|
|
|
50321
|
-
if (
|
|
50326
|
+
if (bShowText)
|
|
50322
50327
|
{
|
|
50323
|
-
|
|
50324
|
-
|
|
50325
|
-
|
|
50326
|
-
|
|
50328
|
+
if (y-textWidth/2<3) //左边位置不够了, 顶着左边画
|
|
50329
|
+
{
|
|
50330
|
+
var yText=y;
|
|
50331
|
+
this.Canvas.save();
|
|
50332
|
+
this.Canvas.translate(xText, yText);
|
|
50333
|
+
this.Canvas.rotate(90 * Math.PI / 180); //数据和框子旋转180度
|
|
50327
50334
|
|
|
50328
|
-
|
|
50329
|
-
|
|
50330
|
-
|
|
50331
|
-
|
|
50332
|
-
|
|
50335
|
+
this.Canvas.fillRect(0,0,textWidth,this.TextHeight);
|
|
50336
|
+
this.Canvas.textAlign="left";
|
|
50337
|
+
this.Canvas.textBaseline="middle";
|
|
50338
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
50339
|
+
this.Canvas.fillText(text,2,this.TextHeight/2,textWidth);
|
|
50333
50340
|
|
|
50334
|
-
|
|
50335
|
-
|
|
50336
|
-
|
|
50337
|
-
|
|
50338
|
-
|
|
50339
|
-
|
|
50340
|
-
|
|
50341
|
-
|
|
50341
|
+
this.Canvas.restore();
|
|
50342
|
+
}
|
|
50343
|
+
else if (y+textWidth/2>=bottom)
|
|
50344
|
+
{
|
|
50345
|
+
var yText=y;
|
|
50346
|
+
this.Canvas.save();
|
|
50347
|
+
this.Canvas.translate(xText, yText);
|
|
50348
|
+
this.Canvas.rotate(90 * Math.PI / 180); //数据和框子旋转180度
|
|
50342
50349
|
|
|
50343
|
-
|
|
50344
|
-
|
|
50345
|
-
|
|
50346
|
-
|
|
50347
|
-
|
|
50350
|
+
this.Canvas.fillRect(-textWidth,0,textWidth,this.TextHeight);
|
|
50351
|
+
this.Canvas.textAlign="right";
|
|
50352
|
+
this.Canvas.textBaseline="middle";
|
|
50353
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
50354
|
+
this.Canvas.fillText(text,-2,this.TextHeight/2,textWidth);
|
|
50348
50355
|
|
|
50349
|
-
|
|
50350
|
-
|
|
50351
|
-
|
|
50352
|
-
|
|
50353
|
-
|
|
50354
|
-
|
|
50355
|
-
|
|
50356
|
-
|
|
50356
|
+
this.Canvas.restore();
|
|
50357
|
+
}
|
|
50358
|
+
else
|
|
50359
|
+
{
|
|
50360
|
+
var yText=y;
|
|
50361
|
+
this.Canvas.save();
|
|
50362
|
+
this.Canvas.translate(xText, yText);
|
|
50363
|
+
this.Canvas.rotate(90 * Math.PI / 180); //数据和框子旋转180度
|
|
50357
50364
|
|
|
50358
|
-
|
|
50359
|
-
|
|
50360
|
-
|
|
50361
|
-
|
|
50362
|
-
|
|
50365
|
+
this.Canvas.fillRect(-textWidth/2,0,textWidth,this.TextHeight);
|
|
50366
|
+
this.Canvas.textAlign="center";
|
|
50367
|
+
this.Canvas.textBaseline="middle";
|
|
50368
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
50369
|
+
this.Canvas.fillText(text,0,this.TextHeight/2,textWidth);
|
|
50363
50370
|
|
|
50364
|
-
|
|
50371
|
+
this.Canvas.restore();
|
|
50372
|
+
}
|
|
50365
50373
|
}
|
|
50366
50374
|
}
|
|
50367
50375
|
|
|
@@ -66847,6 +66855,7 @@ function JSChartResource()
|
|
|
66847
66855
|
},
|
|
66848
66856
|
|
|
66849
66857
|
ArrowType:0,
|
|
66858
|
+
EnableIndexArrow:true, //指标数值是否带上涨下跌箭头
|
|
66850
66859
|
|
|
66851
66860
|
NameArrow:{ Color:"rgb(43,54,69)", Space:2, Symbol:'▼' },
|
|
66852
66861
|
}
|
|
@@ -68148,6 +68157,7 @@ function JSChartResource()
|
|
|
68148
68157
|
}
|
|
68149
68158
|
|
|
68150
68159
|
if (IFrameSplitOperator.IsNumber(item.ArrowType)) this.IndexTitle.ArrowType=item.ArrowType;
|
|
68160
|
+
if (IFrameSplitOperator.IsBool(item.EnableIndexArrow)) this.IndexTitle.EnableIndexArrow=item.EnableIndexArrow;
|
|
68151
68161
|
|
|
68152
68162
|
if (item.NameArrow)
|
|
68153
68163
|
{
|
|
@@ -70931,6 +70941,7 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
70931
70941
|
this.ChartCorssCursor.StringFormatY.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
70932
70942
|
this.ChartCorssCursor.StringFormatY.LanguageID=this.LanguageID;
|
|
70933
70943
|
this.ChartCorssCursor.StringFormatY.ExtendChartPaint=this.ExtendChartPaint;
|
|
70944
|
+
this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
70934
70945
|
|
|
70935
70946
|
//创建等待提示
|
|
70936
70947
|
this.ChartSplashPaint = new ChartSplashPaint();
|
|
@@ -79538,6 +79549,7 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
|
|
|
79538
79549
|
this.ChartCorssCursor.StringFormatY.LanguageID=this.LanguageID;
|
|
79539
79550
|
this.ChartCorssCursor.StringFormatY.ShareAfterVol=this.ShareAfterVol;
|
|
79540
79551
|
this.ChartCorssCursor.CallAcutionXOperator=new CallAcutionXOperator();
|
|
79552
|
+
this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
79541
79553
|
|
|
79542
79554
|
|
|
79543
79555
|
//创建等待提示
|
|
@@ -85147,6 +85159,7 @@ function KLineChartHScreenContainer(uielement)
|
|
|
85147
85159
|
this.ChartCorssCursor.StringFormatY=g_DivTooltipDataForamt.Create("CorssCursor_YStringFormat");
|
|
85148
85160
|
this.ChartCorssCursor.StringFormatY.LanguageID=this.LanguageID;
|
|
85149
85161
|
this.ChartCorssCursor.StringFormatY.ExtendChartPaint=this.ExtendChartPaint;
|
|
85162
|
+
this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
85150
85163
|
|
|
85151
85164
|
//创建等待提示
|
|
85152
85165
|
this.ChartSplashPaint = new ChartSplashPaint();
|
|
@@ -85292,6 +85305,7 @@ function MinuteChartHScreenContainer(uielement)
|
|
|
85292
85305
|
this.ChartCorssCursor.StringFormatY=g_DivTooltipDataForamt.Create("CorssCursor_YStringFormat");
|
|
85293
85306
|
this.ChartCorssCursor.StringFormatY.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
85294
85307
|
this.ChartCorssCursor.CallAcutionXOperator=new CallAcutionXOperator();
|
|
85308
|
+
this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
85295
85309
|
|
|
85296
85310
|
//创建等待提示
|
|
85297
85311
|
this.ChartSplashPaint = new ChartSplashPaint();
|
|
@@ -6538,6 +6538,7 @@ var JSCHART_EVENT_ID=
|
|
|
6538
6538
|
ON_FORMAT_CALL_AUCTION_INDEX_TITLE:153, //集合竞价指标窗口标题内容
|
|
6539
6539
|
|
|
6540
6540
|
ON_FORMAT_KLINE_HIGH_LOW_TITLE:154, //K线最高最低价格式化内容
|
|
6541
|
+
ON_CUSTOM_CORSSCURSOR_POSITION:155, //自定义十字光标X轴的输出的位置
|
|
6541
6542
|
}
|
|
6542
6543
|
|
|
6543
6544
|
var JSCHART_OPERATOR_ID=
|
|
@@ -14225,7 +14226,7 @@ function IChartFramePainting()
|
|
|
14225
14226
|
|
|
14226
14227
|
this.YSpecificMaxMin=null; //指定Y轴最大最小值
|
|
14227
14228
|
this.IsShowBorder = true; //是否显示边框
|
|
14228
|
-
this.IsShowTitleArrow=
|
|
14229
|
+
this.IsShowTitleArrow=g_JSChartResource.IndexTitle.EnableIndexArrow; //是否显示指标信息上涨下跌箭头
|
|
14229
14230
|
this.TitleArrowType=g_JSChartResource.IndexTitle.ArrowType; //指标信息上涨下跌箭头类型 0=独立颜色 1=跟指标名字颜色一致
|
|
14230
14231
|
this.IsShowIndexName=true; //是否显示指标名字
|
|
14231
14232
|
this.IsShowOverlayIndexName=true; //是否显示叠加指标名字
|
|
@@ -53665,8 +53666,8 @@ function ChartCorssCursor()
|
|
|
53665
53666
|
}
|
|
53666
53667
|
}
|
|
53667
53668
|
|
|
53668
|
-
//X轴 Bottom
|
|
53669
|
-
if ((this.ShowTextMode.Bottom==1 || this.ShowTextMode.Bottom==2 || this.ShowTextMode.Bottom==
|
|
53669
|
+
//X轴 Bottom==8 自定义
|
|
53670
|
+
if ((this.ShowTextMode.Bottom==1 || this.ShowTextMode.Bottom==2 || this.ShowTextMode.Bottom==8) && this.StringFormatX.Operator())
|
|
53670
53671
|
{
|
|
53671
53672
|
var text=this.StringFormatX.Text;
|
|
53672
53673
|
this.Canvas.font=this.Font;
|
|
@@ -53675,49 +53676,53 @@ function ChartCorssCursor()
|
|
|
53675
53676
|
|
|
53676
53677
|
var yCenter=bottom+2+this.TextHeight/2;
|
|
53677
53678
|
var yTop=bottom+2;
|
|
53679
|
+
var bShowText=true;
|
|
53678
53680
|
if (this.ShowTextMode.Bottom==2)
|
|
53679
53681
|
{
|
|
53680
53682
|
yCenter=bottom-this.TextHeight/2-2;
|
|
53681
53683
|
yTop=bottom-this.TextHeight-2;
|
|
53682
53684
|
}
|
|
53683
|
-
else if (this.ShowTextMode.Bottom==
|
|
53685
|
+
else if (this.ShowTextMode.Bottom==8)
|
|
53684
53686
|
{
|
|
53685
|
-
var
|
|
53686
|
-
if (
|
|
53687
|
+
var event=this.GetEventCallback(JSCHART_EVENT_ID.ON_CUSTOM_CORSSCURSOR_POSITION);
|
|
53688
|
+
if (event && event.Callback)
|
|
53687
53689
|
{
|
|
53688
|
-
var
|
|
53689
|
-
|
|
53690
|
-
|
|
53691
|
-
|
|
53692
|
-
|
|
53693
|
-
|
|
53690
|
+
var sendData={ YCenter:yCenter, YTop:yTop, Height:this.TextHeight, IsShowText:bShowText };
|
|
53691
|
+
event.Callback(event, sendData, this);
|
|
53692
|
+
|
|
53693
|
+
yCenter=sendData.YCenter;
|
|
53694
|
+
yTop=sendData.YTop;
|
|
53695
|
+
bShowText=sendData.IsShowText;
|
|
53694
53696
|
}
|
|
53695
53697
|
}
|
|
53696
53698
|
|
|
53697
53699
|
//JSConsole.Chart.Log('[ChartCorssCursor::Draw] ',yCenter);
|
|
53698
|
-
if (
|
|
53700
|
+
if (bShowText)
|
|
53699
53701
|
{
|
|
53700
|
-
|
|
53701
|
-
|
|
53702
|
-
|
|
53703
|
-
|
|
53704
|
-
|
|
53705
|
-
|
|
53706
|
-
|
|
53707
|
-
|
|
53708
|
-
|
|
53709
|
-
|
|
53710
|
-
|
|
53711
|
-
|
|
53712
|
-
|
|
53713
|
-
|
|
53714
|
-
|
|
53715
|
-
|
|
53716
|
-
|
|
53717
|
-
|
|
53718
|
-
|
|
53719
|
-
|
|
53720
|
-
|
|
53702
|
+
if (x-textWidth/2<3) //左边位置不够了, 顶着左边画
|
|
53703
|
+
{
|
|
53704
|
+
this.DrawTextBGRect(x-1,yTop,textWidth,this.TextHeight);
|
|
53705
|
+
this.Canvas.textAlign="left";
|
|
53706
|
+
this.Canvas.textBaseline="middle";
|
|
53707
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
53708
|
+
this.Canvas.fillText(text,x+1,yCenter,textWidth);
|
|
53709
|
+
}
|
|
53710
|
+
else if (x+textWidth/2>=right)
|
|
53711
|
+
{
|
|
53712
|
+
this.DrawTextBGRect(right-textWidth,yTop,textWidth,this.TextHeight);
|
|
53713
|
+
this.Canvas.textAlign="right";
|
|
53714
|
+
this.Canvas.textBaseline="middle";
|
|
53715
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
53716
|
+
this.Canvas.fillText(text,right-2,yCenter,textWidth);
|
|
53717
|
+
}
|
|
53718
|
+
else
|
|
53719
|
+
{
|
|
53720
|
+
this.DrawTextBGRect(x-textWidth/2,yTop,textWidth,this.TextHeight);
|
|
53721
|
+
this.Canvas.textAlign="center";
|
|
53722
|
+
this.Canvas.textBaseline="middle";
|
|
53723
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
53724
|
+
this.Canvas.fillText(text,x,yCenter,textWidth);
|
|
53725
|
+
}
|
|
53721
53726
|
}
|
|
53722
53727
|
}
|
|
53723
53728
|
|
|
@@ -54221,7 +54226,7 @@ function ChartCorssCursor()
|
|
|
54221
54226
|
}
|
|
54222
54227
|
|
|
54223
54228
|
//X轴 Bottom=10 使用第1个指标框位置
|
|
54224
|
-
if ((this.ShowTextMode.Bottom===1 || this.ShowTextMode.Bottom==
|
|
54229
|
+
if ((this.ShowTextMode.Bottom===1 || this.ShowTextMode.Bottom==8) && this.StringFormatX.Operator())
|
|
54225
54230
|
{
|
|
54226
54231
|
var text=this.StringFormatX.Text;
|
|
54227
54232
|
this.Canvas.font=this.Font;
|
|
@@ -54229,64 +54234,67 @@ function ChartCorssCursor()
|
|
|
54229
54234
|
this.Canvas.fillStyle=this.TextBGColor;
|
|
54230
54235
|
var textWidth=this.Canvas.measureText(text).width+4; //前后各空2个像素
|
|
54231
54236
|
var xText=left;
|
|
54232
|
-
|
|
54233
|
-
if (this.ShowTextMode.Bottom==
|
|
54237
|
+
var bShowText=true;
|
|
54238
|
+
if (this.ShowTextMode.Bottom==8)
|
|
54234
54239
|
{
|
|
54235
|
-
var
|
|
54236
|
-
if (
|
|
54240
|
+
var event=this.GetEventCallback(JSCHART_EVENT_ID.ON_CUSTOM_CORSSCURSOR_POSITION);
|
|
54241
|
+
if (event && event.Callback)
|
|
54237
54242
|
{
|
|
54238
|
-
var
|
|
54239
|
-
|
|
54240
|
-
|
|
54241
|
-
|
|
54242
|
-
|
|
54243
|
+
var sendData={ XText:xText, Height:this.TextHeight, IsShowText:bShowText };
|
|
54244
|
+
event.Callback(event, sendData, this);
|
|
54245
|
+
|
|
54246
|
+
xText=sendData.XText;
|
|
54247
|
+
bShowText=sendData.IsShowText;
|
|
54243
54248
|
}
|
|
54244
54249
|
}
|
|
54245
54250
|
|
|
54246
|
-
if (
|
|
54251
|
+
if (bShowText)
|
|
54247
54252
|
{
|
|
54248
|
-
|
|
54249
|
-
|
|
54250
|
-
|
|
54251
|
-
|
|
54253
|
+
if (y-textWidth/2<3) //左边位置不够了, 顶着左边画
|
|
54254
|
+
{
|
|
54255
|
+
var yText=y;
|
|
54256
|
+
this.Canvas.save();
|
|
54257
|
+
this.Canvas.translate(xText, yText);
|
|
54258
|
+
this.Canvas.rotate(90 * Math.PI / 180); //数据和框子旋转180度
|
|
54252
54259
|
|
|
54253
|
-
|
|
54254
|
-
|
|
54255
|
-
|
|
54256
|
-
|
|
54257
|
-
|
|
54260
|
+
this.Canvas.fillRect(0,0,textWidth,this.TextHeight);
|
|
54261
|
+
this.Canvas.textAlign="left";
|
|
54262
|
+
this.Canvas.textBaseline="middle";
|
|
54263
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
54264
|
+
this.Canvas.fillText(text,2,this.TextHeight/2,textWidth);
|
|
54258
54265
|
|
|
54259
|
-
|
|
54260
|
-
|
|
54261
|
-
|
|
54262
|
-
|
|
54263
|
-
|
|
54264
|
-
|
|
54265
|
-
|
|
54266
|
-
|
|
54266
|
+
this.Canvas.restore();
|
|
54267
|
+
}
|
|
54268
|
+
else if (y+textWidth/2>=bottom)
|
|
54269
|
+
{
|
|
54270
|
+
var yText=y;
|
|
54271
|
+
this.Canvas.save();
|
|
54272
|
+
this.Canvas.translate(xText, yText);
|
|
54273
|
+
this.Canvas.rotate(90 * Math.PI / 180); //数据和框子旋转180度
|
|
54267
54274
|
|
|
54268
|
-
|
|
54269
|
-
|
|
54270
|
-
|
|
54271
|
-
|
|
54272
|
-
|
|
54275
|
+
this.Canvas.fillRect(-textWidth,0,textWidth,this.TextHeight);
|
|
54276
|
+
this.Canvas.textAlign="right";
|
|
54277
|
+
this.Canvas.textBaseline="middle";
|
|
54278
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
54279
|
+
this.Canvas.fillText(text,-2,this.TextHeight/2,textWidth);
|
|
54273
54280
|
|
|
54274
|
-
|
|
54275
|
-
|
|
54276
|
-
|
|
54277
|
-
|
|
54278
|
-
|
|
54279
|
-
|
|
54280
|
-
|
|
54281
|
-
|
|
54281
|
+
this.Canvas.restore();
|
|
54282
|
+
}
|
|
54283
|
+
else
|
|
54284
|
+
{
|
|
54285
|
+
var yText=y;
|
|
54286
|
+
this.Canvas.save();
|
|
54287
|
+
this.Canvas.translate(xText, yText);
|
|
54288
|
+
this.Canvas.rotate(90 * Math.PI / 180); //数据和框子旋转180度
|
|
54282
54289
|
|
|
54283
|
-
|
|
54284
|
-
|
|
54285
|
-
|
|
54286
|
-
|
|
54287
|
-
|
|
54290
|
+
this.Canvas.fillRect(-textWidth/2,0,textWidth,this.TextHeight);
|
|
54291
|
+
this.Canvas.textAlign="center";
|
|
54292
|
+
this.Canvas.textBaseline="middle";
|
|
54293
|
+
this.Canvas.fillStyle=this.TextColor;
|
|
54294
|
+
this.Canvas.fillText(text,0,this.TextHeight/2,textWidth);
|
|
54288
54295
|
|
|
54289
|
-
|
|
54296
|
+
this.Canvas.restore();
|
|
54297
|
+
}
|
|
54290
54298
|
}
|
|
54291
54299
|
}
|
|
54292
54300
|
|
|
@@ -70772,6 +70780,7 @@ function JSChartResource()
|
|
|
70772
70780
|
},
|
|
70773
70781
|
|
|
70774
70782
|
ArrowType:0,
|
|
70783
|
+
EnableIndexArrow:true, //指标数值是否带上涨下跌箭头
|
|
70775
70784
|
|
|
70776
70785
|
NameArrow:{ Color:"rgb(43,54,69)", Space:2, Symbol:'▼' },
|
|
70777
70786
|
}
|
|
@@ -72073,6 +72082,7 @@ function JSChartResource()
|
|
|
72073
72082
|
}
|
|
72074
72083
|
|
|
72075
72084
|
if (IFrameSplitOperator.IsNumber(item.ArrowType)) this.IndexTitle.ArrowType=item.ArrowType;
|
|
72085
|
+
if (IFrameSplitOperator.IsBool(item.EnableIndexArrow)) this.IndexTitle.EnableIndexArrow=item.EnableIndexArrow;
|
|
72076
72086
|
|
|
72077
72087
|
if (item.NameArrow)
|
|
72078
72088
|
{
|
|
@@ -74856,6 +74866,7 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
74856
74866
|
this.ChartCorssCursor.StringFormatY.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
74857
74867
|
this.ChartCorssCursor.StringFormatY.LanguageID=this.LanguageID;
|
|
74858
74868
|
this.ChartCorssCursor.StringFormatY.ExtendChartPaint=this.ExtendChartPaint;
|
|
74869
|
+
this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
74859
74870
|
|
|
74860
74871
|
//创建等待提示
|
|
74861
74872
|
this.ChartSplashPaint = new ChartSplashPaint();
|
|
@@ -83463,6 +83474,7 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
|
|
|
83463
83474
|
this.ChartCorssCursor.StringFormatY.LanguageID=this.LanguageID;
|
|
83464
83475
|
this.ChartCorssCursor.StringFormatY.ShareAfterVol=this.ShareAfterVol;
|
|
83465
83476
|
this.ChartCorssCursor.CallAcutionXOperator=new CallAcutionXOperator();
|
|
83477
|
+
this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
83466
83478
|
|
|
83467
83479
|
|
|
83468
83480
|
//创建等待提示
|
|
@@ -89072,6 +89084,7 @@ function KLineChartHScreenContainer(uielement)
|
|
|
89072
89084
|
this.ChartCorssCursor.StringFormatY=g_DivTooltipDataForamt.Create("CorssCursor_YStringFormat");
|
|
89073
89085
|
this.ChartCorssCursor.StringFormatY.LanguageID=this.LanguageID;
|
|
89074
89086
|
this.ChartCorssCursor.StringFormatY.ExtendChartPaint=this.ExtendChartPaint;
|
|
89087
|
+
this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
89075
89088
|
|
|
89076
89089
|
//创建等待提示
|
|
89077
89090
|
this.ChartSplashPaint = new ChartSplashPaint();
|
|
@@ -89217,6 +89230,7 @@ function MinuteChartHScreenContainer(uielement)
|
|
|
89217
89230
|
this.ChartCorssCursor.StringFormatY=g_DivTooltipDataForamt.Create("CorssCursor_YStringFormat");
|
|
89218
89231
|
this.ChartCorssCursor.StringFormatY.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
89219
89232
|
this.ChartCorssCursor.CallAcutionXOperator=new CallAcutionXOperator();
|
|
89233
|
+
this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
|
|
89220
89234
|
|
|
89221
89235
|
//创建等待提示
|
|
89222
89236
|
this.ChartSplashPaint = new ChartSplashPaint();
|
|
@@ -137167,7 +137181,7 @@ function ScrollBarBGChart()
|
|
|
137167
137181
|
|
|
137168
137182
|
|
|
137169
137183
|
|
|
137170
|
-
var HQCHART_VERSION="1.1.
|
|
137184
|
+
var HQCHART_VERSION="1.1.13622";
|
|
137171
137185
|
|
|
137172
137186
|
function PrintHQChartVersion()
|
|
137173
137187
|
{
|