hqchart 1.1.14731 → 1.1.14734

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.
@@ -5249,7 +5249,7 @@ function JSChart(divElement, bOffscreen, bCacheCanvas)
5249
5249
  if (item.BottomSpace>=0) chart.Frame.SubFrame[i].Frame.ChartBorder.BottomSpace=item.BottomSpace*pixelRatio;
5250
5250
 
5251
5251
  //是否显示关闭集合竞价按钮
5252
- if (IFrameSplitOperator.IsNumber(item.CloseBeforeButton)) chart.Frame.SubFrame[i].Frame.IsShowCloseButton=item.CloseBeforeButton;
5252
+ if (IFrameSplitOperator.IsBool(item.CloseBeforeButton)) chart.Frame.SubFrame[i].Frame.IsShowCloseButton=item.CloseBeforeButton;
5253
5253
 
5254
5254
  if (item.ClientBGColor) subFrame.ClientBGColor=item.ClientBGColor;
5255
5255
  if (!IFrameSplitOperator.IsUndefined(item.HorizontalReserved)) subFrame.HorizontalReserved=item.HorizontalReserved;
@@ -14360,6 +14360,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
14360
14360
  frame.YSplitOperator.ChartBorder=frame.ChartBorder;
14361
14361
  frame.YSplitOperator.SplitCount=subFrame.Frame.YSplitOperator.SplitCount;
14362
14362
  frame.YSplitOperator.GetEventCallback=(id)=> { return this.GetEventCallback(id); };
14363
+ frame.YSplitOperator.HQChart=this;
14363
14364
 
14364
14365
  overlayFrame.Frame=frame;
14365
14366
 
@@ -15293,6 +15294,27 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
15293
15294
  chart.Canvas=this.Canvas;
15294
15295
  chart.ChartBorder=frame.ChartBorder;
15295
15296
  chart.ChartFrame=frame;
15297
+ chart.HQChart=this;
15298
+
15299
+ this.ChartPaintEx.push(chart);
15300
+
15301
+ return true;
15302
+ }
15303
+
15304
+ this.CreateChartPaintExtendV2=function(className, option, windowIndex)
15305
+ {
15306
+ if (windowIndex<0) return false;
15307
+ var subFrame=this.Frame.SubFrame[windowIndex];
15308
+ if (!subFrame || !subFrame.Frame) return false;
15309
+
15310
+ var chart=g_ChartPaintFactory.Create(className, option);
15311
+ if (!chart) return false;
15312
+
15313
+ var frame=subFrame.Frame;
15314
+ chart.Canvas=this.Canvas;
15315
+ chart.ChartBorder=frame.ChartBorder;
15316
+ chart.ChartFrame=frame;
15317
+ chart.HQChart=this;
15296
15318
 
15297
15319
  this.ChartPaintEx.push(chart);
15298
15320
 
@@ -15835,6 +15857,12 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
15835
15857
 
15836
15858
  return true;
15837
15859
  }
15860
+
15861
+ //是否是额外的集合竞价部分
15862
+ this.IsCallAuctionFrame=function(frameID)
15863
+ {
15864
+ return false;
15865
+ }
15838
15866
  }
15839
15867
 
15840
15868
  function GetDevicePixelRatio()
@@ -29863,6 +29891,7 @@ function ChartPaintFactory()
29863
29891
  ["ChartMinuteVolumBar",{ Create:function(option) { return new ChartMinuteVolumBar(); } }], //分时成交量柱子
29864
29892
  ["ChartMinutePriceLine",{ Create:function(option) { return new ChartMinutePriceLine();} }],
29865
29893
  ["ChartMinuteBuySellBar", { Create:function(option){ return new ChartMinuteBuySellBar(); }}],
29894
+ ["ChartMinuteBarCallAuction", { Create:function(option){ return new ChartMinuteBarCallAuction(); }}]
29866
29895
  ]);
29867
29896
 
29868
29897
  this.Create=function(name, option)
@@ -38732,6 +38761,8 @@ function ChartMinuteVolumBar()
38732
38761
  var isHScreen=(this.ChartFrame.IsHScreen===true);
38733
38762
  var yPrice=this.YClose; //上一分钟的价格
38734
38763
  var yBottom=this.ChartFrame.GetYFromData(0);
38764
+ var yBottom=border.BottomEx;
38765
+ if (isHScreen) yBottom=border.LeftEx;
38735
38766
  var unit=this.GetVolUnit();
38736
38767
  if (callAutionData.Ver==1.0)
38737
38768
  {
@@ -38922,6 +38953,28 @@ function ChartMinuteVolumBar()
38922
38953
 
38923
38954
  }
38924
38955
 
38956
+ //只画集合竞价柱子
38957
+ function ChartMinuteBarCallAuction()
38958
+ {
38959
+ this.newMethod=ChartMinuteVolumBar; //派生
38960
+ this.newMethod();
38961
+ delete this.newMethod;
38962
+
38963
+ this.ClassName="ChartMinuteBarCallAuction";
38964
+
38965
+ this.Draw=function()
38966
+ {
38967
+ if (!this.IsShow || this.ChartFrame.IsMinSize || !this.IsVisible) return;
38968
+ if (this.IsShowIndexTitleOnly()) return;
38969
+
38970
+ this.DrawBeforeOpen();
38971
+ this.DrawMultiDayBeforeOpen();
38972
+
38973
+ this.DrawAfterClose();
38974
+ this.DrawMultiDayAfterClose();
38975
+ }
38976
+ }
38977
+
38925
38978
  function ChartErrorMessage()
38926
38979
  {
38927
38980
  this.newMethod=IChartPainting; //派生
@@ -44277,6 +44330,8 @@ function ChartOverlayMinutePriceLine()
44277
44330
  }
44278
44331
 
44279
44332
 
44333
+
44334
+
44280
44335
  //分钟持仓线
44281
44336
  function ChartMinutePositionLine()
44282
44337
  {
@@ -58404,7 +58459,8 @@ function FrameSplitY()
58404
58459
 
58405
58460
  this.CallAcutionSplitY=function(count,splitData)
58406
58461
  {
58407
- if (this.Frame.Identify!=1) return null;
58462
+ if (!this.IsCallAuctionFrame()) return;
58463
+
58408
58464
  var aryCallAcution=this.GetCallAcutionSplitY(count,splitData);
58409
58465
  if (!aryCallAcution) return;
58410
58466
 
@@ -58432,9 +58488,18 @@ function FrameSplitY()
58432
58488
  }
58433
58489
  }
58434
58490
 
58491
+ this.IsCallAuctionFrame=function()
58492
+ {
58493
+ if (this.Frame.Identify==1) return true;
58494
+
58495
+ if (!this.HQChart || !this.HQChart.IsCallAuctionFrame) return false;
58496
+
58497
+ return this.HQChart.IsCallAuctionFrame(this.Frame.Identify);
58498
+ }
58499
+
58435
58500
  this.GetCallAcutionSplitY=function(count,splitData)
58436
58501
  {
58437
- if (this.Frame.Identify!=1) return null;
58502
+ if (!this.IsCallAuctionFrame()) return null;
58438
58503
 
58439
58504
  var isBeforeData=(this.IsBeforeData==true && this.BeforeOpenData && (this.BeforeOpenData.Ver==2.0 || this.BeforeOpenData.Ver==3.0));
58440
58505
  var isAfterData=(this.IsAfterData==true && this.AfterCloseData && (this.AfterCloseData.Ver==2.0 || this.AfterCloseData.Ver==3.0));
@@ -58449,7 +58514,7 @@ function FrameSplitY()
58449
58514
  for(var i=0;i<count;++i)
58450
58515
  {
58451
58516
  var item=new CoordinateInfo();
58452
- var yValue=intervalY*i;
58517
+ var yValue=intervalY*i+splitData.Min;
58453
58518
  item.Value=yValue;
58454
58519
  item.LineType=8;
58455
58520
  if (isBeforeData )
@@ -58499,7 +58564,7 @@ function FrameSplitY()
58499
58564
  for(var i=0;i<count;++i)
58500
58565
  {
58501
58566
  var item=new CoordinateInfo();
58502
- var yValue=intervalY*i;
58567
+ var yValue=intervalY*i+splitData.Min;
58503
58568
  item.Value=yValue;
58504
58569
  item.LineType=9;
58505
58570
  var isVaild=false;
@@ -61843,6 +61908,7 @@ function HQPriceStringFormat()
61843
61908
  this.RComplexText; //{ Space:2 间距, Text:[ {Color:, Text: }] } 支持单行多颜色
61844
61909
  this.Point;
61845
61910
  this.ClientPos=-1;
61911
+ this.HQChart;
61846
61912
 
61847
61913
  this.ExtendChartPaint;
61848
61914
  this.RExtendText=[];
@@ -61995,6 +62061,32 @@ function HQPriceStringFormat()
61995
62061
  if (this.DataFormatType==1) this.Text=IFrameSplitOperator.FormatValueThousandsString(this.Value,defaultfloatPrecision);
61996
62062
  else this.Text=IFrameSplitOperator.FormatValueString(this.Value,defaultfloatPrecision,this.LanguageID);
61997
62063
  if (IFrameSplitOperator.IsNumber(this.RValue)) this.RText=IFrameSplitOperator.FormatValueString(this.RValue,defaultfloatPrecision,this.LanguageID);
62064
+
62065
+ var bCallAuction=false;
62066
+ if (this.HQChart && this.HQChart.IsCallAuctionFrame)
62067
+ bCallAuction=this.HQChart.IsCallAuctionFrame(this.FrameID);
62068
+
62069
+ if (bCallAuction)
62070
+ {
62071
+ if (this.ClientPos==2)
62072
+ {
62073
+ this.GetBeforeOpen();
62074
+ }
62075
+ else if (this.ClientPos==3)
62076
+ {
62077
+ if (this.ShareAfterVol==0 || this.ShareAfterVol==2)
62078
+ this.GetAfterClose();
62079
+ }
62080
+ else if (this.ClientPos>=200 && this.ClientPos<=299)
62081
+ {
62082
+ this.GetMultiDayBeforeOpen();
62083
+ }
62084
+ else if (this.ClientPos>=300 && this.ClientPos<=399 )
62085
+ {
62086
+ if (this.ShareAfterVol==0 || this.ShareAfterVol==2)
62087
+ this.GetMultiDayAfterClose();
62088
+ }
62089
+ }
61998
62090
  }
61999
62091
 
62000
62092
  if (this.GetEventCallback)
@@ -65133,8 +65225,11 @@ function DynamicChartTitlePainting()
65133
65225
  if (this.IsMinuteFrame && this.PointInfo && ( this.PointInfo.ClientPos==2 || this.PointInfo.ClientPos==3 || (this.PointInfo.ClientPos>=200&& this.PointInfo.ClientPos<=299) || (this.PointInfo.ClientPos>=300&& this.PointInfo.ClientPos<=399) ))
65134
65226
  {
65135
65227
  var result={ PreventDefault:false }
65136
- this.DrawMainCallAuction({ Left:left, Right:right, Bottom:bottom }, rtText, result);
65137
- if (result.PreventDefault===false) this.DrawMainIndexTitle({ Left:left, Right:right, Bottom:bottom }, isShowLastData, rtText);
65228
+ var yRight=right;
65229
+ if (this.Frame.ToolbarCacheSize && this.Frame.ToolbarCacheSize.RToolbar) yRight=this.Frame.ToolbarCacheSize.RToolbar.Left-2; //右侧按钮宽度要去掉
65230
+ this.DrawMainCallAuction({ Left:left, Right:yRight, Bottom:bottom }, rtText, result);
65231
+ if (result.PreventDefault===false) this.DrawMainIndexTitle({ Left:left, Right:yRight, Bottom:bottom }, isShowLastData, rtText);
65232
+ if (IFrameSplitOperator.IsNumber(rtText.Bottom)) bottom=rtText.Bottom;
65138
65233
  }
65139
65234
  else
65140
65235
  {
@@ -83395,6 +83490,7 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
83395
83490
  this.ChartCorssCursor.StringFormatY.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
83396
83491
  this.ChartCorssCursor.StringFormatY.LanguageID=this.LanguageID;
83397
83492
  this.ChartCorssCursor.StringFormatY.ExtendChartPaint=this.ExtendChartPaint;
83493
+ this.ChartCorssCursor.StringFormatY.HQChart=this;
83398
83494
  this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
83399
83495
  this.ChartCorssCursor.OnChangeStatusCallback=(data, obj)=>{ this.OnChangeCorssCursorStatus(data,obj); }
83400
83496
 
@@ -93262,6 +93358,7 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
93262
93358
  this.ChartCorssCursor.StringFormatY.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
93263
93359
  this.ChartCorssCursor.StringFormatY.LanguageID=this.LanguageID;
93264
93360
  this.ChartCorssCursor.StringFormatY.ShareAfterVol=this.ShareAfterVol;
93361
+ this.ChartCorssCursor.StringFormatY.HQChart=this;
93265
93362
  this.ChartCorssCursor.CallAcutionXOperator=new CallAcutionXOperator();
93266
93363
  this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
93267
93364
  this.ChartCorssCursor.OnChangeStatusCallback=(data, obj)=>{ this.OnChangeCorssCursorStatus(data,obj); }
@@ -93379,6 +93476,7 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
93379
93476
  frame.YSplitOperator.LanguageID=this.LanguageID;
93380
93477
  frame.YSplitOperator.FrameSplitData=this.FrameSplitData.get('double');
93381
93478
  frame.YSplitOperator.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
93479
+ frame.YSplitOperator.HQChart=this;
93382
93480
  if (i==1) frame.YSplitOperator.ShareAfterVol=this.ShareAfterVol;
93383
93481
  }
93384
93482
 
@@ -93454,6 +93552,7 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
93454
93552
  frame.YSplitOperator.FrameSplitData=this.FrameSplitData.get('double');
93455
93553
  frame.YSplitOperator.Frame=frame;
93456
93554
  frame.YSplitOperator.ChartBorder=border;
93555
+ frame.YSplitOperator.HQChart=this;
93457
93556
  frame.XSplitOperator=new FrameSplitMinuteX();
93458
93557
  frame.XSplitOperator.Frame=frame;
93459
93558
  frame.XSplitOperator.ChartBorder=border;
@@ -95850,6 +95949,20 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
95850
95949
  this.ChartPaint[2].MultiDayBeforeOpenData=multiBeforeOpenData;
95851
95950
  this.ChartPaint[2].MultiDayAfterCloseData=multiAfterCloseData;
95852
95951
 
95952
+ for(var i=0;i<this.ChartPaintEx.length;++i)
95953
+ {
95954
+ var item=this.ChartPaintEx[i];
95955
+ if (item.ClassName=="ChartMinuteBarCallAuction")
95956
+ {
95957
+ item.YClose=yClose;
95958
+ item.Symbol=this.Symbol;
95959
+ item.BeforeOpenData=this.BeforeOpenData;
95960
+ item.AfterCloseData=this.AfterCloseData;
95961
+ item.MultiDayBeforeOpenData=multiBeforeOpenData;
95962
+ item.MultiDayAfterCloseData=multiAfterCloseData;
95963
+ }
95964
+ }
95965
+
95853
95966
  for(var i in this.Frame.SubFrame)
95854
95967
  {
95855
95968
  var item=this.Frame.SubFrame[i];
@@ -95962,6 +96075,7 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
95962
96075
  frame.YSplitOperator.FrameSplitData=this.FrameSplitData.get('double');
95963
96076
  frame.YSplitOperator.Frame=frame;
95964
96077
  frame.YSplitOperator.ChartBorder=frame.ChartBorder;
96078
+ frame.YSplitOperator.HQChart=this;
95965
96079
  frame.YSplitOperator.SplitCount=subFrame.Frame.YSplitOperator.SplitCount;
95966
96080
  frame.YSplitOperator.GetEventCallback=(id)=> { return this.GetEventCallback(id); };
95967
96081
  frame.YSplitOperator.OverlayIdentify=overlayFrame.Identify;
@@ -96964,6 +97078,25 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
96964
97078
 
96965
97079
  return data;
96966
97080
  }
97081
+
97082
+ this.IsCallAuctionFrame=function(frameID)
97083
+ {
97084
+ if (!IFrameSplitOperator.IsNonEmptyArray(this.ChartPaintEx)) return false;
97085
+ if (!IFrameSplitOperator.IsNonEmptyArray(this.Frame.SubFrame)) return false;
97086
+ if (frameID<0 || frameID>=this.Frame.SubFrame.length) return false;
97087
+ var subItem=this.Frame.SubFrame[frameID];
97088
+ if (!subItem || !subItem.Frame) return false;
97089
+
97090
+ var subFrame=subItem.Frame;
97091
+ for(var i=0;i<this.ChartPaintEx.length;++i)
97092
+ {
97093
+ var item=this.ChartPaintEx[i];
97094
+ if (item.ChartFrame && item.ChartFrame.Guid==subFrame.Guid)
97095
+ return true;
97096
+ }
97097
+
97098
+ return false;
97099
+ }
96967
97100
  }
96968
97101
 
96969
97102
  //盘前数据
@@ -98787,6 +98920,7 @@ function KLineChartHScreenContainer(uielement)
98787
98920
  this.ChartCorssCursor.StringFormatY=g_DivTooltipDataForamt.Create("CorssCursor_YStringFormat");
98788
98921
  this.ChartCorssCursor.StringFormatY.LanguageID=this.LanguageID;
98789
98922
  this.ChartCorssCursor.StringFormatY.ExtendChartPaint=this.ExtendChartPaint;
98923
+ this.ChartCorssCursor.StringFormatY.HQChart=this;
98790
98924
  this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
98791
98925
 
98792
98926
  //创建等待提示
@@ -98968,6 +99102,7 @@ function MinuteChartHScreenContainer(uielement)
98968
99102
  this.ChartCorssCursor.StringFormatX.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
98969
99103
  this.ChartCorssCursor.StringFormatY=g_DivTooltipDataForamt.Create("CorssCursor_YStringFormat");
98970
99104
  this.ChartCorssCursor.StringFormatY.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
99105
+ this.ChartCorssCursor.StringFormatY.HQChart=this;
98971
99106
  this.ChartCorssCursor.CallAcutionXOperator=new CallAcutionXOperator();
98972
99107
  this.ChartCorssCursor.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
98973
99108
 
@@ -99045,6 +99180,7 @@ function MinuteChartHScreenContainer(uielement)
99045
99180
  frame.YSplitOperator.LanguageID=this.LanguageID;
99046
99181
  frame.YSplitOperator.FrameSplitData=this.FrameSplitData.get('double');
99047
99182
  frame.YSplitOperator.GetEventCallback=(id)=> { return this.GetEventCallback(id); }
99183
+ frame.YSplitOperator.HQChart=this;
99048
99184
  }
99049
99185
 
99050
99186
  frame.YSplitOperator.Frame=frame;
@@ -158812,7 +158948,7 @@ function HQChartScriptWorker()
158812
158948
 
158813
158949
 
158814
158950
 
158815
- var HQCHART_VERSION="1.1.14730";
158951
+ var HQCHART_VERSION="1.1.14733";
158816
158952
 
158817
158953
  function PrintHQChartVersion()
158818
158954
  {