hqchart 1.1.13720 → 1.1.13728

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.
@@ -16199,8 +16199,11 @@ function AverageWidthFrame()
16199
16199
  var pixelTatio = GetDevicePixelRatio();
16200
16200
  var defaultTextHeight=18*pixelTatio;
16201
16201
  var textHeight=defaultTextHeight;
16202
+ var y;
16203
+ if (item.Value=="Top") y=top;
16204
+ else if (item.Value=="Bottom") y=bottom;
16205
+ else y = this.GetYFromData(item.Value);
16202
16206
 
16203
- var y = this.GetYFromData(item.Value);
16204
16207
  var position=0;
16205
16208
  var emptyBGColor;
16206
16209
  if (item.ExtendData && item.ExtendData.Custom)
@@ -17739,6 +17742,7 @@ function MinuteFrame()
17739
17742
  {
17740
17743
  case 0:
17741
17744
  case 1:
17745
+ case 10://自定义的
17742
17746
  this.DrawCustomItem(item); //自定义刻度
17743
17747
  break;
17744
17748
  }
@@ -20377,6 +20381,7 @@ function KLineFrame()
20377
20381
  case 2: //当前屏最后一个K线价格刻度
20378
20382
  case 3: //主图K线涨幅刻度
20379
20383
  case 4: //叠加K线涨幅刻度
20384
+ case 10://自定义的
20380
20385
  this.DrawCustomItem(item, mapTextRect);
20381
20386
  break;
20382
20387
  }
@@ -127951,6 +127956,7 @@ function JSReportChartContainer(uielement)
127951
127956
 
127952
127957
  stock.Symbol=this.GetSymbolNoSuffix(symbol);
127953
127958
  stock.Name=item[1];
127959
+ if (IFrameSplitOperator.IsNumber(item[88])) stock.PriceColorType=item[88];
127954
127960
  this.ReadStockJsonData(stock, item);
127955
127961
  }
127956
127962
  }
@@ -128195,7 +128201,9 @@ function JSReportChartContainer(uielement)
128195
128201
  {
128196
128202
  //0=证券代码 1=股票名称 2=昨收 3=开 4=高 5=低 6=收 7=成交量 8=成交金额, 9=买价 10=买量 11=卖价 12=卖量 13=均价 14=流通股 15=总股本 16=涨停价 17=跌停价
128197
128203
  //18=内盘 19=外盘 20=现量 21=涨幅% 22=涨跌 23=换手率% 24=振幅% 25=流通市值 26=总市值
128198
- //30=全局扩展数据 31=当前板块扩展数据
128204
+ //30=全局扩展数据 31=当前板块扩展数据 36=日期字段
128205
+
128206
+ //88=价格颜色类型
128199
128207
 
128200
128208
  if (IFrameSplitOperator.IsString(item[1])) stock.Name=item[1];
128201
128209
  if (IFrameSplitOperator.IsNumber(item[2])) stock.YClose=item[2];
@@ -128278,6 +128286,19 @@ function JSReportChartContainer(uielement)
128278
128286
  if (IFrameSplitOperator.IsNumber(item[36])) stock.Date=item[36]; //日期
128279
128287
 
128280
128288
  if (IFrameSplitOperator.IsBool(item[37])) stock.Checked=item[37];
128289
+
128290
+ if (IFrameSplitOperator.IsNumber(item[38])) stock.Position=item[38]; //持仓量
128291
+ if (IFrameSplitOperator.IsNumber(item[39])) stock.FClose=item[39]; //结算价
128292
+ if (IFrameSplitOperator.IsNumber(item[40])) stock.YFClose=item[40]; //昨结算价
128293
+ if (IFrameSplitOperator.IsNumber(item[41])) stock.OpenPosition=item[41]; //开仓量
128294
+ if (IFrameSplitOperator.IsNumber(item[42])) stock.ClosePosition=item[42]; //平仓量
128295
+
128296
+ //1,3,5,10,15 涨速%
128297
+ if (IFrameSplitOperator.IsNumber(item[43])) stock.RSpeed1M=item[43];
128298
+ if (IFrameSplitOperator.IsNumber(item[44])) stock.RSpeed3M=item[44];
128299
+ if (IFrameSplitOperator.IsNumber(item[45])) stock.RSpeed5M=item[45];
128300
+ if (IFrameSplitOperator.IsNumber(item[46])) stock.RSpeed10M=item[46];
128301
+ if (IFrameSplitOperator.IsNumber(item[47])) stock.RSpeed15M=item[47];
128281
128302
  }
128282
128303
 
128283
128304
 
@@ -128462,6 +128483,8 @@ function JSReportChartContainer(uielement)
128462
128483
  if (!reportChart) return;
128463
128484
 
128464
128485
  var keyID = e.keyCode ? e.keyCode :e.which;
128486
+ if (keyID==116) return; //F15刷新不处理
128487
+
128465
128488
  switch(keyID)
128466
128489
  {
128467
128490
  case 33: //page up
@@ -130079,6 +130102,7 @@ function JSReportChartContainer(uielement)
130079
130102
  {
130080
130103
  var item=tabItem.ArySubMenu[i];
130081
130104
  var menuItem={ Name:item.Title, Data:{ ID:item.CommandID, Args:[item.ID]} };
130105
+ if (item.Text) menuItem.Text=item.Text;
130082
130106
 
130083
130107
  aryMenu.push(menuItem);
130084
130108
  }
@@ -130769,6 +130793,20 @@ var REPORT_COLUMN_ID=
130769
130793
 
130770
130794
  CHECKBOX_ID:33, //单选框
130771
130795
 
130796
+ FUTURES_POSITION_ID:34, //期货持仓量
130797
+ FUTURES_CLOSE_ID:35, //期货结算价
130798
+ FUTURES_YCLOSE_ID:36, //期货昨结算
130799
+ FUTURES_OPEN_POSITION_ID:37, //期货开仓量
130800
+ FUTURES_CLOSE_POSITION_ID:38, //期货平仓量
130801
+
130802
+
130803
+ //1,3,5,10,15分钟涨速
130804
+ RISING_SPEED_1M_ID:60,
130805
+ RISING_SPEED_3M_ID:61,
130806
+ RISING_SPEED_5M_ID:62,
130807
+ RISING_SPEED_10M_ID:63,
130808
+ RISING_SPEED_15M_ID:64,
130809
+
130772
130810
  SYMBOL_NAME_ID:99,
130773
130811
 
130774
130812
  CUSTOM_STRING_TEXT_ID:100, //自定义字符串文本
@@ -130781,6 +130819,7 @@ var REPORT_COLUMN_ID=
130781
130819
  CUSTOM_LINK_ID:107, //链接
130782
130820
  }
130783
130821
 
130822
+ //数据对应字段名对照表
130784
130823
  var MAP_COLUMN_FIELD=new Map([
130785
130824
  [REPORT_COLUMN_ID.SYMBOL_ID, "Symbol"],
130786
130825
  [REPORT_COLUMN_ID.NAME_ID, "Name"],
@@ -130816,6 +130855,18 @@ var MAP_COLUMN_FIELD=new Map([
130816
130855
  [REPORT_COLUMN_ID.NAME_EX_ID, "NameEx"],
130817
130856
 
130818
130857
  [REPORT_COLUMN_ID.DATE_ID, "Date"],
130858
+
130859
+ [REPORT_COLUMN_ID.FUTURES_POSITION_ID, "Position"],
130860
+ [REPORT_COLUMN_ID.FUTURES_CLOSE_ID, "FClose"],
130861
+ [REPORT_COLUMN_ID.FUTURES_YCLOSE_ID, "YFClose"],
130862
+ [REPORT_COLUMN_ID.FUTURES_OPEN_POSITION_ID, "OpenPosition"],
130863
+ [REPORT_COLUMN_ID.FUTURES_CLOSE_POSITION_ID, "ClosePosition"],
130864
+
130865
+ [REPORT_COLUMN_ID.RISING_SPEED_1M_ID, "RSpeed1M"],
130866
+ [REPORT_COLUMN_ID.RISING_SPEED_3M_ID, "RSpeed3M"],
130867
+ [REPORT_COLUMN_ID.RISING_SPEED_5M_ID, "RSpeed5M"],
130868
+ [REPORT_COLUMN_ID.RISING_SPEED_10M_ID, "RSpeed10M"],
130869
+ [REPORT_COLUMN_ID.RISING_SPEED_15M_ID, "RSpeed15M"],
130819
130870
  ]);
130820
130871
 
130821
130872
  function ChartReport()
@@ -131319,7 +131370,19 @@ function ChartReport()
131319
131370
 
131320
131371
  { Type:REPORT_COLUMN_ID.CUSTOM_BUTTON_ID, Title:"", TextAlign:"center", FixedWidth:50*GetDevicePixelRatio() },
131321
131372
  { Type:REPORT_COLUMN_ID.CUSTOM_PROGRESS_ID, Title:"进度条", TextAlign:"center", FixedWidth:100*GetDevicePixelRatio() },
131322
- { Type:REPORT_COLUMN_ID.CUSTOM_LINK_ID, Title:"链接地址", TextAlign:"center", MaxText:"擎擎擎擎擎" }
131373
+ { Type:REPORT_COLUMN_ID.CUSTOM_LINK_ID, Title:"链接地址", TextAlign:"center", MaxText:"擎擎擎擎擎" },
131374
+
131375
+ { Type:REPORT_COLUMN_ID.FUTURES_POSITION_ID, Title:"持仓量", TextAlign:"right", TextColor:g_JSChartResource.Report.FieldColor.Vol, Width:null, MaxText:"8888888" },
131376
+ { Type:REPORT_COLUMN_ID.FUTURES_CLOSE_ID, Title:"结算价", TextAlign:"right", Width:null, MaxText:"8888888" },
131377
+ { Type:REPORT_COLUMN_ID.FUTURES_YCLOSE_ID, Title:"昨结算价", TextAlign:"right", Width:null, MaxText:"8888888" },
131378
+ { Type:REPORT_COLUMN_ID.FUTURES_OPEN_POSITION_ID, Title:"开仓量", TextAlign:"right", TextColor:g_JSChartResource.Report.FieldColor.Text, Width:null, MaxText:"8888888" },
131379
+ { Type:REPORT_COLUMN_ID.FUTURES_CLOSE_POSITION_ID, Title:"平仓量", TextAlign:"right", TextColor:g_JSChartResource.Report.FieldColor.Text, Width:null, MaxText:"8888888" },
131380
+
131381
+ { Type:REPORT_COLUMN_ID.RISING_SPEED_1M_ID, Title:"涨速%", TextAlign:"right", Width:null, MaxText:"-888.88" },
131382
+ { Type:REPORT_COLUMN_ID.RISING_SPEED_3M_ID, Title:"3分涨速%", TextAlign:"right", Width:null, MaxText:"-888.88" },
131383
+ { Type:REPORT_COLUMN_ID.RISING_SPEED_5M_ID, Title:"5分涨速%", TextAlign:"right", Width:null, MaxText:"-888.88" },
131384
+ { Type:REPORT_COLUMN_ID.RISING_SPEED_10M_ID, Title:"10分涨速%", TextAlign:"right", Width:null, MaxText:"-888.88" },
131385
+ { Type:REPORT_COLUMN_ID.RISING_SPEED_15M_ID, Title:"15分涨速%", TextAlign:"right", Width:null, MaxText:"-888.88" },
131323
131386
  ];
131324
131387
 
131325
131388
  for(var i=0;i<DEFAULT_COLUMN.length;++i)
@@ -132148,6 +132211,17 @@ function ChartReport()
132148
132211
 
132149
132212
  this.FormatDrawInfo(column, stock, drawInfo, data);
132150
132213
  }
132214
+ else if (column.Type==REPORT_COLUMN_ID.FUTURES_CLOSE_ID || column.Type==REPORT_COLUMN_ID.FUTURES_YCLOSE_ID)
132215
+ {
132216
+ var fieldName=MAP_COLUMN_FIELD.get(column.Type);
132217
+ if (stock && IFrameSplitOperator.IsNumber(stock[fieldName]))
132218
+ {
132219
+ var value=stock[fieldName];
132220
+ this.GetPriceDrawInfo(value, stock, data, drawInfo);
132221
+ }
132222
+
132223
+ this.FormatDrawInfo(column, stock, drawInfo, data);
132224
+ }
132151
132225
  else if (column.Type==REPORT_COLUMN_ID.SELL_PRICE_ID)
132152
132226
  {
132153
132227
  if (stock) this.GetPriceDrawInfo(stock.SellPrice, stock, data, drawInfo);
@@ -132217,7 +132291,9 @@ function ChartReport()
132217
132291
 
132218
132292
  this.FormatDrawInfo(column, stock, drawInfo, data);
132219
132293
  }
132220
- else if (column.Type==REPORT_COLUMN_ID.INCREASE_ID || column.Type==REPORT_COLUMN_ID.AMPLITUDE_ID || column.Type==REPORT_COLUMN_ID.UPDOWN_ID)
132294
+ else if (column.Type==REPORT_COLUMN_ID.INCREASE_ID || column.Type==REPORT_COLUMN_ID.AMPLITUDE_ID || column.Type==REPORT_COLUMN_ID.UPDOWN_ID ||
132295
+ column.Type==REPORT_COLUMN_ID.RISING_SPEED_1M_ID || column.Type==REPORT_COLUMN_ID.RISING_SPEED_3M_ID || column.Type==REPORT_COLUMN_ID.RISING_SPEED_5M_ID ||
132296
+ column.Type==REPORT_COLUMN_ID.RISING_SPEED_10M_ID || column.Type==REPORT_COLUMN_ID.RISING_SPEED_15M_ID )
132221
132297
  {
132222
132298
  var fieldName=MAP_COLUMN_FIELD.get(column.Type);
132223
132299
  if (stock && IFrameSplitOperator.IsNumber(stock[fieldName]))
@@ -132229,6 +132305,18 @@ function ChartReport()
132229
132305
 
132230
132306
  this.FormatDrawInfo(column, stock, drawInfo, data);
132231
132307
  }
132308
+ else if (column.Type==REPORT_COLUMN_ID.FUTURES_POSITION_ID || column.Type==REPORT_COLUMN_ID.FUTURES_OPEN_POSITION_ID || column.Type==REPORT_COLUMN_ID.FUTURES_CLOSE_POSITION_ID)
132309
+ {
132310
+ //持仓量原始值输出
132311
+ var fieldName=MAP_COLUMN_FIELD.get(column.Type);
132312
+ if (stock && IFrameSplitOperator.IsNumber(stock[fieldName]))
132313
+ {
132314
+ var value=stock[fieldName];
132315
+ drawInfo.Text=value.toFixed(0);
132316
+ }
132317
+
132318
+ this.FormatDrawInfo(column, stock, drawInfo, data);
132319
+ }
132232
132320
  else if (column.Type==REPORT_COLUMN_ID.CUSTOM_STRING_TEXT_ID)
132233
132321
  {
132234
132322
  this.GetCustomStringDrawInfo(data, column, drawInfo);
@@ -132751,10 +132839,21 @@ function ChartReport()
132751
132839
  if (!IFrameSplitOperator.IsNumber(price)) return false;
132752
132840
 
132753
132841
  drawInfo.Text=price.toFixed(data.Decimal);
132754
- if (!IFrameSplitOperator.IsNumber(stock.YClose))
132842
+
132843
+ var yClose=null;
132844
+ if (stock.PriceColorType===1) //昨结算价 计算颜色
132845
+ {
132846
+ if (IFrameSplitOperator.IsNumber(stock.YFClose)) yClose=stock.YFClose;
132847
+ }
132848
+ else //昨收价 计算颜色
132849
+ {
132850
+ if (IFrameSplitOperator.IsNumber(stock.YClose)) yClose=stock.YClose;
132851
+ }
132852
+
132853
+ if (!IFrameSplitOperator.IsNumber(yClose))
132755
132854
  drawInfo.TextColor=this.UnchagneColor;
132756
132855
  else
132757
- drawInfo.TextColor=this.GetUpDownColor(price, stock.YClose);
132856
+ drawInfo.TextColor=this.GetUpDownColor(price, yClose);
132758
132857
 
132759
132858
  if (option && option.LimitBG)
132760
132859
  {
@@ -140807,7 +140906,7 @@ function JSPopMenu()
140807
140906
  }
140808
140907
  else if (i==2) //快捷方式
140809
140908
  {
140810
-
140909
+ if (item.Text) tdDom.innerText=item.Text;
140811
140910
  }
140812
140911
  else if (i==3) //箭头
140813
140912
  {
@@ -142368,6 +142467,7 @@ function JSPopKeyboard()
142368
142467
  this.InputDOM=null;
142369
142468
  this.Title="HQChart 键盘精灵"
142370
142469
  this.ID=Guid();
142470
+ this.ActiveDOM=null; //启动键盘精灵是的控件
142371
142471
 
142372
142472
  this.Keyboard=
142373
142473
  {
@@ -142563,6 +142663,11 @@ function JSPopKeyboard()
142563
142663
  this.DivDialog.style.visibility='hidden';
142564
142664
  this.InputDOM.value="";
142565
142665
  this.Keyboard.JSChart.ClearSearch();
142666
+ if (this.ActiveDOM)
142667
+ {
142668
+ if (this.ActiveDOM.focus) this.ActiveDOM.focus(); //把焦点换回去
142669
+ this.ActiveDOM=null;
142670
+ }
142566
142671
  }
142567
142672
 
142568
142673
  this.IsShow=function()
@@ -142580,6 +142685,7 @@ function JSPopKeyboard()
142580
142685
  {
142581
142686
  this.Show();
142582
142687
  this.InputDOM.focus();
142688
+ if (event.target) this.ActiveDOM=event.target;
142583
142689
  }
142584
142690
  else if (code==27 && this.IsShow())
142585
142691
  {
@@ -142757,7 +142863,7 @@ function HQChartScriptWorker()
142757
142863
 
142758
142864
 
142759
142865
 
142760
- var HQCHART_VERSION="1.1.13719";
142866
+ var HQCHART_VERSION="1.1.13727";
142761
142867
 
142762
142868
  function PrintHQChartVersion()
142763
142869
  {