hqchart 1.1.14280 → 1.1.14286
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 +36 -16
- package/package.json +1 -1
- package/src/jscommon/umychart.complier.js +120 -1
- package/src/jscommon/umychart.js +261 -1
- package/src/jscommon/umychart.style.js +7 -0
- package/src/jscommon/umychart.uniapp.h5/umychart.uniapp.h5.js +389 -3
- package/src/jscommon/umychart.version.js +1 -1
- package/src/jscommon/umychart.vue/umychart.vue.js +389 -3
|
@@ -35426,6 +35426,225 @@ function ChartKLineTable()
|
|
|
35426
35426
|
}
|
|
35427
35427
|
}
|
|
35428
35428
|
|
|
35429
|
+
//表格
|
|
35430
|
+
function ChartSimpleTable()
|
|
35431
|
+
{
|
|
35432
|
+
this.newMethod=IChartPainting; //派生
|
|
35433
|
+
this.newMethod();
|
|
35434
|
+
delete this.newMethod;
|
|
35435
|
+
|
|
35436
|
+
this.ClassName='ChartSimpleTable'; //类名
|
|
35437
|
+
//this.Data;
|
|
35438
|
+
|
|
35439
|
+
this.TextFontConfig=CloneData(g_JSChartResource.ChartSimpleTable.TextFont);
|
|
35440
|
+
this.ItemMargin=CloneData(g_JSChartResource.ChartSimpleTable.ItemMargin);
|
|
35441
|
+
this.TextColor=g_JSChartResource.ChartSimpleTable.TextColor; //默认颜色
|
|
35442
|
+
this.BGColor=g_JSChartResource.ChartSimpleTable.BGColor; //背景色
|
|
35443
|
+
this.BorderColor=g_JSChartResource.ChartSimpleTable.BorderColor; //边框颜色
|
|
35444
|
+
this.Offset={ X:-3, Y:0 }, //位置偏移
|
|
35445
|
+
|
|
35446
|
+
|
|
35447
|
+
this.DefaultCellWidth=30;
|
|
35448
|
+
|
|
35449
|
+
this.RectClient={ };
|
|
35450
|
+
this.AryColumnCache=[]; //列缓存
|
|
35451
|
+
this.TextFontHeight;
|
|
35452
|
+
this.TextFont;
|
|
35453
|
+
this.RowHeight; //行高
|
|
35454
|
+
|
|
35455
|
+
this.ReloadResource=function(resource)
|
|
35456
|
+
{
|
|
35457
|
+
this.TextFontConfig=CloneData(g_JSChartResource.ChartSimpleTable.TextFont);
|
|
35458
|
+
this.ItemMargin=CloneData(g_JSChartResource.ChartSimpleTable.ItemMargin);
|
|
35459
|
+
this.TextColor=g_JSChartResource.ChartSimpleTable.TextColor; //默认颜色
|
|
35460
|
+
this.BGColor=g_JSChartResource.ChartSimpleTable.BGColor; //背景色
|
|
35461
|
+
this.BorderColor=g_JSChartResource.ChartSimpleTable.BorderColor; //边框颜色
|
|
35462
|
+
}
|
|
35463
|
+
|
|
35464
|
+
this.CalculateSize=function()
|
|
35465
|
+
{
|
|
35466
|
+
this.AryColumnCache=[];
|
|
35467
|
+
|
|
35468
|
+
var pixelRatio=GetDevicePixelRatio();
|
|
35469
|
+
this.TextFont=`${this.TextFontConfig.Size*pixelRatio}px ${ this.TextFontConfig.Name}`;
|
|
35470
|
+
this.TextFontHeight=this.GetFontHeight(this.TextFont,"擎");
|
|
35471
|
+
this.RowHeight=this.TextFontHeight+this.ItemMargin.Top+this.ItemMargin.Bottom;
|
|
35472
|
+
|
|
35473
|
+
var rowCount=this.Data.Data.length;
|
|
35474
|
+
for(var i=0, j=0;i<rowCount;++i)
|
|
35475
|
+
{
|
|
35476
|
+
var rowItem=this.Data.Data[i];
|
|
35477
|
+
for(j=0;j<rowItem.AryCell.length;++j)
|
|
35478
|
+
{
|
|
35479
|
+
if (!this.AryColumnCache[j]) this.AryColumnCache[j]={ Width:this.DefaultCellWidth };
|
|
35480
|
+
var colItem=this.AryColumnCache[j];
|
|
35481
|
+
|
|
35482
|
+
var cellItem=rowItem.AryCell[j];
|
|
35483
|
+
var textWidth=this.Canvas.measureText(cellItem.Text).width;
|
|
35484
|
+
if (colItem.Width<textWidth) colItem.Width=textWidth;
|
|
35485
|
+
}
|
|
35486
|
+
}
|
|
35487
|
+
|
|
35488
|
+
var tableWidth=0;
|
|
35489
|
+
for(var i=0;i<this.AryColumnCache.length;++i)
|
|
35490
|
+
{
|
|
35491
|
+
var item=this.AryColumnCache[i];
|
|
35492
|
+
item.Width+=(this.ItemMargin.Left+this.ItemMargin.Right); //增加左右间距
|
|
35493
|
+
|
|
35494
|
+
tableWidth+=item.Width;
|
|
35495
|
+
}
|
|
35496
|
+
|
|
35497
|
+
this.RectClient={ Width:tableWidth, Height:this.RowHeight*rowCount };
|
|
35498
|
+
|
|
35499
|
+
var border=this.ChartFrame.GetBorder();
|
|
35500
|
+
this.RectClient.Right=border.Right+this.Offset.X;
|
|
35501
|
+
this.RectClient.Top=border.TopEx+this.Offset.Y;
|
|
35502
|
+
this.RectClient.Left=this.RectClient.Right-this.RectClient.Width;
|
|
35503
|
+
this.RectClient.Bottom=this.RectClient.Top+this.RectClient.Height;
|
|
35504
|
+
}
|
|
35505
|
+
|
|
35506
|
+
this.Draw=function()
|
|
35507
|
+
{
|
|
35508
|
+
if (!this.IsShow || this.ChartFrame.IsMinSize) return;
|
|
35509
|
+
if (!this.Data || !IFrameSplitOperator.IsNonEmptyArray(this.Data.Data)) return;
|
|
35510
|
+
|
|
35511
|
+
var isHScreen=(this.ChartFrame.IsHScreen===true);
|
|
35512
|
+
if (isHScreen) return;
|
|
35513
|
+
|
|
35514
|
+
this.CalculateSize();
|
|
35515
|
+
|
|
35516
|
+
if (this.BGColor)
|
|
35517
|
+
{
|
|
35518
|
+
this.Canvas.fillStyle=this.BGColor;
|
|
35519
|
+
this.Canvas.fillRect(this.RectClient.Left, this.RectClient.Top, this.RectClient.Width, this.RectClient.Height);
|
|
35520
|
+
}
|
|
35521
|
+
|
|
35522
|
+
var itemHeight=this.RowHeight;
|
|
35523
|
+
this.Canvas.font=this.TextFont;
|
|
35524
|
+
this.Canvas.textBaseline='bottom';
|
|
35525
|
+
this.Canvas.textAlign='left';
|
|
35526
|
+
var rtRow={ Left:this.RectClient.Left, Top:this.RectClient.Top, Width:this.RectClient.Width, Height:itemHeight };
|
|
35527
|
+
rtRow.Right=rtRow.Left+rtRow.Width;
|
|
35528
|
+
rtRow.Bottom=rtRow.Top+rtRow.Height;
|
|
35529
|
+
var rowCount=this.Data.Data.length;
|
|
35530
|
+
for(var i=0;i<rowCount;++i)
|
|
35531
|
+
{
|
|
35532
|
+
var rowItem=this.Data.Data[i];
|
|
35533
|
+
this.DrawRow(rowItem, rtRow);
|
|
35534
|
+
|
|
35535
|
+
rtRow.Top+=itemHeight;
|
|
35536
|
+
rtRow.Bottom+=itemHeight;
|
|
35537
|
+
}
|
|
35538
|
+
|
|
35539
|
+
this.DrawBorder();
|
|
35540
|
+
}
|
|
35541
|
+
|
|
35542
|
+
this.DrawBorder=function()
|
|
35543
|
+
{
|
|
35544
|
+
if (!this.BorderColor) return;
|
|
35545
|
+
|
|
35546
|
+
var rowCount=this.Data.Data.length;
|
|
35547
|
+
var colCount=this.AryColumnCache.length;
|
|
35548
|
+
this.Canvas.strokeStyle=this.BorderColor;
|
|
35549
|
+
this.Canvas.beginPath();
|
|
35550
|
+
|
|
35551
|
+
//横线
|
|
35552
|
+
var rowTop=this.RectClient.Top;
|
|
35553
|
+
var left=this.RectClient.Left, right=this.RectClient.Right;
|
|
35554
|
+
var bottom=this.RectClient.Bottom, top=this.RectClient.Top;
|
|
35555
|
+
for(var i=0;i<rowCount;++i)
|
|
35556
|
+
{
|
|
35557
|
+
if (i==0)
|
|
35558
|
+
{
|
|
35559
|
+
var drawTop=ToFixedPoint(rowTop);
|
|
35560
|
+
this.Canvas.moveTo(left,drawTop);
|
|
35561
|
+
this.Canvas.lineTo(right,drawTop);
|
|
35562
|
+
}
|
|
35563
|
+
|
|
35564
|
+
var drawTop=ToFixedPoint(rowTop+this.RowHeight);
|
|
35565
|
+
this.Canvas.moveTo(left,drawTop);
|
|
35566
|
+
this.Canvas.lineTo(right,drawTop);
|
|
35567
|
+
|
|
35568
|
+
rowTop+=this.RowHeight;
|
|
35569
|
+
}
|
|
35570
|
+
|
|
35571
|
+
//竖线
|
|
35572
|
+
var columnLeft=this.RectClient.Left;
|
|
35573
|
+
for(var i=0;i<colCount; ++i)
|
|
35574
|
+
{
|
|
35575
|
+
var item=this.AryColumnCache[i];
|
|
35576
|
+
|
|
35577
|
+
if (i==0)
|
|
35578
|
+
{
|
|
35579
|
+
var drawLeft=ToFixedPoint(columnLeft);
|
|
35580
|
+
this.Canvas.moveTo(drawLeft,top);
|
|
35581
|
+
this.Canvas.lineTo(drawLeft,bottom);
|
|
35582
|
+
}
|
|
35583
|
+
|
|
35584
|
+
var drawLeft=ToFixedPoint(columnLeft+item.Width);
|
|
35585
|
+
this.Canvas.moveTo(drawLeft,top);
|
|
35586
|
+
this.Canvas.lineTo(drawLeft,bottom);
|
|
35587
|
+
|
|
35588
|
+
columnLeft+=item.Width;
|
|
35589
|
+
}
|
|
35590
|
+
|
|
35591
|
+
this.Canvas.stroke();
|
|
35592
|
+
}
|
|
35593
|
+
|
|
35594
|
+
this.DrawRow=function(data, rtRow)
|
|
35595
|
+
{
|
|
35596
|
+
if (!IFrameSplitOperator.IsNonEmptyArray(data.AryCell)) return;
|
|
35597
|
+
|
|
35598
|
+
var x=rtRow.Left,y=rtRow.Top, width=rtRow.Width;
|
|
35599
|
+
for(var i=0;i<data.AryCell.length;++i)
|
|
35600
|
+
{
|
|
35601
|
+
var item=data.AryCell[i];
|
|
35602
|
+
var colItem=this.AryColumnCache[i];
|
|
35603
|
+
|
|
35604
|
+
var rtBG={Left:x, Top:rtRow.Top, Bottom:rtRow.Bottom, Height:this.RowHeight, Width:colItem.Width };
|
|
35605
|
+
rtBG.Right=rtBG.Left+rtBG.Width;
|
|
35606
|
+
|
|
35607
|
+
if (item)
|
|
35608
|
+
{
|
|
35609
|
+
if (item.BGColor)
|
|
35610
|
+
{
|
|
35611
|
+
this.Canvas.fillStyle=item.BGColor;
|
|
35612
|
+
this.Canvas.fillRect(rtBG.Left, rtBG.Top, rtBG.Width, rtBG.Height);
|
|
35613
|
+
}
|
|
35614
|
+
|
|
35615
|
+
if (item.Text && rtBG.Width>10)
|
|
35616
|
+
{
|
|
35617
|
+
if (item.Color) this.Canvas.fillStyle=item.Color;
|
|
35618
|
+
else this.Canvas.fillStyle=this.TextColor
|
|
35619
|
+
|
|
35620
|
+
var xText=x+this.ItemMargin.Left;
|
|
35621
|
+
var yText=rtBG.Bottom-this.ItemMargin.Bottom;
|
|
35622
|
+
|
|
35623
|
+
if (item.TextAlign=='right')
|
|
35624
|
+
{
|
|
35625
|
+
var textWidth=this.Canvas.measureText(item.Text).width;
|
|
35626
|
+
xText=rtBG.Right-this.ItemMargin.Right-textWidth;
|
|
35627
|
+
}
|
|
35628
|
+
else if (item.TextAlign=='center')
|
|
35629
|
+
{
|
|
35630
|
+
var textWidth=this.Canvas.measureText(item.Text).width;
|
|
35631
|
+
xText=rtBG.Left+rtBG.Width/2-textWidth/2;
|
|
35632
|
+
}
|
|
35633
|
+
|
|
35634
|
+
this.Canvas.fillText(item.Text,xText,yText);
|
|
35635
|
+
}
|
|
35636
|
+
}
|
|
35637
|
+
|
|
35638
|
+
x+=rtBG.Width;
|
|
35639
|
+
}
|
|
35640
|
+
}
|
|
35641
|
+
|
|
35642
|
+
this.GetMaxMin=function()
|
|
35643
|
+
{
|
|
35644
|
+
return { Min:null, Max:null };
|
|
35645
|
+
}
|
|
35646
|
+
}
|
|
35647
|
+
|
|
35429
35648
|
//分钟成交量 支持横屏
|
|
35430
35649
|
function ChartMinuteVolumBar()
|
|
35431
35650
|
{
|
|
@@ -74022,6 +74241,15 @@ function JSChartResource()
|
|
|
74022
74241
|
ItemMergin:{ Left:5, Right:5, Top:4, Bottom:2 },
|
|
74023
74242
|
};
|
|
74024
74243
|
|
|
74244
|
+
this.ChartSimpleTable=
|
|
74245
|
+
{
|
|
74246
|
+
TextFont:{ Family:'微软雅黑' , Size:14 },
|
|
74247
|
+
ItemMargin:{ Left:5, Right:5, Top:4, Bottom:2 },
|
|
74248
|
+
TextColor:"rgb(0,0,0)",
|
|
74249
|
+
BGColor:"rgba(255,255,255,0.95)",
|
|
74250
|
+
BorderColor:"rgb(217,217,217)",
|
|
74251
|
+
}
|
|
74252
|
+
|
|
74025
74253
|
//手机端tooltip
|
|
74026
74254
|
this.TooltipPaint = {
|
|
74027
74255
|
BGColor:'rgba(250,250,250,0.8)', //背景色
|
|
@@ -75250,6 +75478,8 @@ function JSChartResource()
|
|
|
75250
75478
|
if (style.Title.PositionColor) this.Title.PositionColor=style.Title.PositionColor;
|
|
75251
75479
|
}
|
|
75252
75480
|
|
|
75481
|
+
if (style.ChartSimpleTable) this.SetChartSimpleTable(style.ChartSimpleTable);
|
|
75482
|
+
|
|
75253
75483
|
if (style.DRAWICON)
|
|
75254
75484
|
{
|
|
75255
75485
|
if (style.DRAWICON.Icon)
|
|
@@ -75509,7 +75739,7 @@ function JSChartResource()
|
|
|
75509
75739
|
{
|
|
75510
75740
|
var mergin=header.Mergin;
|
|
75511
75741
|
if (IFrameSplitOperator.IsNumber(mergin.Left)) this.DealList.Header.Mergin.Left=mergin.Left;
|
|
75512
|
-
if (IFrameSplitOperator.IsNumber(mergin.Right)) this.DealList.Header.Mergin.
|
|
75742
|
+
if (IFrameSplitOperator.IsNumber(mergin.Right)) this.DealList.Header.Mergin.Right=mergin.Right;
|
|
75513
75743
|
if (IFrameSplitOperator.IsNumber(mergin.Top)) this.DealList.Header.Mergin.Top=mergin.Top;
|
|
75514
75744
|
if (IFrameSplitOperator.IsNumber(mergin.Bottom)) this.DealList.Header.Mergin.Bottom=mergin.Bottom;
|
|
75515
75745
|
}
|
|
@@ -76295,6 +76525,32 @@ function JSChartResource()
|
|
|
76295
76525
|
if (IFrameSplitOperator.IsBool(style.AddIndexWindow)) dest.AddIndexWindow=style.AddIndexWindow;
|
|
76296
76526
|
}
|
|
76297
76527
|
|
|
76528
|
+
|
|
76529
|
+
this.SetChartSimpleTable=function(style)
|
|
76530
|
+
{
|
|
76531
|
+
var dest=this.ChartSimpleTable;
|
|
76532
|
+
|
|
76533
|
+
if (style.TextColor) dest.TextColor=style.TextColor;
|
|
76534
|
+
if (style.BGColor) dest.BGColor=style.BGColor;
|
|
76535
|
+
if (style.BorderColor) dest.BorderColor=style.BorderColor;
|
|
76536
|
+
|
|
76537
|
+
if (style.TextFont)
|
|
76538
|
+
{
|
|
76539
|
+
var item=style.TextFont;
|
|
76540
|
+
if (item.Name) dest.TextFont.Name=item.Name;
|
|
76541
|
+
if (IFrameSplitOperator.IsNumber(item.Size)) dest.TextFont.Size=item.Size;
|
|
76542
|
+
}
|
|
76543
|
+
|
|
76544
|
+
if (style.ItemMargin)
|
|
76545
|
+
{
|
|
76546
|
+
var margin=style.ItemMargin;
|
|
76547
|
+
if (IFrameSplitOperator.IsNumber(margin.Left)) dest.ItemMargin.Left=margin.Left;
|
|
76548
|
+
if (IFrameSplitOperator.IsNumber(margin.Right)) dest.ItemMargin.Right=margin.Right;
|
|
76549
|
+
if (IFrameSplitOperator.IsNumber(margin.Top)) dest.ItemMargin.Top=margin.Top;
|
|
76550
|
+
if (IFrameSplitOperator.IsNumber(margin.Bottom)) dest.ItemMargin.Bottom=margin.Bottom;
|
|
76551
|
+
}
|
|
76552
|
+
}
|
|
76553
|
+
|
|
76298
76554
|
}
|
|
76299
76555
|
|
|
76300
76556
|
var g_JSChartResource=new JSChartResource();
|
|
@@ -80706,6 +80962,8 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
80706
80962
|
}
|
|
80707
80963
|
else //API周期数据 重新请求数据
|
|
80708
80964
|
{
|
|
80965
|
+
|
|
80966
|
+
|
|
80709
80967
|
if (ChartData.IsDayPeriod(this.Period,true))
|
|
80710
80968
|
{
|
|
80711
80969
|
this.CancelAutoUpdate(); //先停止定时器
|
|
@@ -80713,6 +80971,7 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
80713
80971
|
this.ClearIndexPaint();
|
|
80714
80972
|
this.ResetOverlaySymbolStatus();
|
|
80715
80973
|
this.ResetScrollBar();
|
|
80974
|
+
this.Frame.ClearYCoordinateMaxMin();
|
|
80716
80975
|
this.RequestHistoryData(); //请求日线数据
|
|
80717
80976
|
}
|
|
80718
80977
|
else if (ChartData.IsMinutePeriod(this.Period,true) || ChartData.IsSecondPeriod(this.Period) || ChartData.IsMilliSecondPeriod(this.Period))
|
|
@@ -80722,6 +80981,7 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
80722
80981
|
this.ClearIndexPaint();
|
|
80723
80982
|
this.ResetOverlaySymbolStatus();
|
|
80724
80983
|
this.ResetScrollBar();
|
|
80984
|
+
this.Frame.ClearYCoordinateMaxMin();
|
|
80725
80985
|
this.RequestHistoryMinuteData(); //请求分钟数据
|
|
80726
80986
|
}
|
|
80727
80987
|
}
|
|
@@ -111280,6 +111540,45 @@ function JSDraw(errorHandler,symbolData)
|
|
|
111280
111540
|
|
|
111281
111541
|
return result;
|
|
111282
111542
|
}
|
|
111543
|
+
|
|
111544
|
+
//表格
|
|
111545
|
+
this.TABLE_CELL=function(text, color, textAlign)
|
|
111546
|
+
{
|
|
111547
|
+
var cellItem={ Text:text };
|
|
111548
|
+
if (color) cellItem.Color=color;
|
|
111549
|
+
if (IFrameSplitOperator.IsString(textAlign))
|
|
111550
|
+
{
|
|
111551
|
+
var strValue=textAlign.toLowerCase(); //转小写
|
|
111552
|
+
cellItem.TextAlign=strValue;
|
|
111553
|
+
}
|
|
111554
|
+
|
|
111555
|
+
return cellItem;
|
|
111556
|
+
}
|
|
111557
|
+
|
|
111558
|
+
this.TABLE_ROW=function(aryData)
|
|
111559
|
+
{
|
|
111560
|
+
var aryCell=[];
|
|
111561
|
+
for(var i=0;i<aryData.length;++i)
|
|
111562
|
+
{
|
|
111563
|
+
var item=aryData[i];
|
|
111564
|
+
aryCell.push(item)
|
|
111565
|
+
}
|
|
111566
|
+
|
|
111567
|
+
return aryCell;
|
|
111568
|
+
}
|
|
111569
|
+
|
|
111570
|
+
this.DRAWTABLE=function(aryData)
|
|
111571
|
+
{
|
|
111572
|
+
var tableData=[]
|
|
111573
|
+
for(var i=0;i<aryData.length;++i)
|
|
111574
|
+
{
|
|
111575
|
+
var item=aryData[i];
|
|
111576
|
+
tableData.push({ AryCell:item });
|
|
111577
|
+
}
|
|
111578
|
+
|
|
111579
|
+
|
|
111580
|
+
return result={ DrawData:{ TableData:tableData }, DrawType:'DRAW_SIMPLE_TABLE' };
|
|
111581
|
+
}
|
|
111283
111582
|
}
|
|
111284
111583
|
|
|
111285
111584
|
|
|
@@ -111334,7 +111633,7 @@ JSDraw.prototype.IsDrawFunction=function(name)
|
|
|
111334
111633
|
'DRAWOVERLAYLINE',"FILLRGN", "FILLRGN2","FILLTOPRGN", "FILLBOTTOMRGN", "FILLVERTICALRGN","FLOATRGN","DRAWSL", "DRAWGBK2","DRAWGBK_DIV",
|
|
111335
111634
|
"VERTLINE","HORLINE","TIPICON",
|
|
111336
111635
|
"BUY","SELL","SELLSHORT","BUYSHORT",
|
|
111337
|
-
"DRAWLASTBARICON","DRAWLASTBARNUMBER", "DRAWLASTBARTEXT",
|
|
111636
|
+
"DRAWLASTBARICON","DRAWLASTBARNUMBER", "DRAWLASTBARTEXT","DRAWTABLE",
|
|
111338
111637
|
]);
|
|
111339
111638
|
if (setFunctionName.has(name)) return true;
|
|
111340
111639
|
|
|
@@ -118204,6 +118503,18 @@ function JSExecute(ast,option)
|
|
|
118204
118503
|
node.Out=node.Draw.DrawData.Data;
|
|
118205
118504
|
break;
|
|
118206
118505
|
|
|
118506
|
+
//表格函数
|
|
118507
|
+
case "TABLE_CELL":
|
|
118508
|
+
node.Out=this.Draw.TABLE_CELL(args[0],args[1],args[2]);
|
|
118509
|
+
break;
|
|
118510
|
+
case "TABLE_ROW":
|
|
118511
|
+
node.Out=this.Draw.TABLE_ROW(args);
|
|
118512
|
+
break;
|
|
118513
|
+
case "DRAWTABLE":
|
|
118514
|
+
node.Draw=this.Draw.DRAWTABLE(args);
|
|
118515
|
+
node.Out=[];
|
|
118516
|
+
break;
|
|
118517
|
+
|
|
118207
118518
|
default:
|
|
118208
118519
|
node.Out=this.Algorithm.CallFunction(funcName, args, node, this.SymbolData);
|
|
118209
118520
|
break;
|
|
@@ -121169,6 +121480,29 @@ function ScriptIndex(name,script,args,option)
|
|
|
121169
121480
|
hqChart.ChartPaint.push(chart);
|
|
121170
121481
|
}
|
|
121171
121482
|
|
|
121483
|
+
this.CreateSimpleTable=function(hqChart,windowIndex,varItem,id)
|
|
121484
|
+
{
|
|
121485
|
+
var chart=new ChartSimpleTable();
|
|
121486
|
+
chart.Canvas=hqChart.Canvas;
|
|
121487
|
+
chart.Name=varItem.Name;
|
|
121488
|
+
chart.ChartBorder=hqChart.Frame.SubFrame[windowIndex].Frame.ChartBorder;
|
|
121489
|
+
chart.ChartFrame=hqChart.Frame.SubFrame[windowIndex].Frame;
|
|
121490
|
+
|
|
121491
|
+
if (varItem.Draw && varItem.Draw.DrawData)
|
|
121492
|
+
{
|
|
121493
|
+
var drawData=varItem.Draw.DrawData;
|
|
121494
|
+
if (drawData.TableData) chart.Data.Data=drawData.TableData;
|
|
121495
|
+
if (drawData.BGColor) chart.BGColor=drawData.BGColor;
|
|
121496
|
+
if (drawData.BorderColor) chart.BorderColor=drawData.BorderColor;
|
|
121497
|
+
if (drawData.TextFont) chart.TextFontConfig=drawData.TextFont;
|
|
121498
|
+
if (drawData.TextColor) chart.TextColor=drawData.TextColor;
|
|
121499
|
+
if (IFrameSplitOperator.IsNumber(drawData.XOffset)) chart.Offset.X=drawData.XOffset;
|
|
121500
|
+
if (IFrameSplitOperator.IsNumber(drawData.YOffset)) chart.Offset.Y=drawData.YOffset;
|
|
121501
|
+
}
|
|
121502
|
+
|
|
121503
|
+
hqChart.ChartPaint.push(chart);
|
|
121504
|
+
}
|
|
121505
|
+
|
|
121172
121506
|
this.CreateTradeIcon=function(hqChart,windowIndex,varItem,id)
|
|
121173
121507
|
{
|
|
121174
121508
|
var chart=new ChartTradeIcon();
|
|
@@ -122034,6 +122368,9 @@ function ScriptIndex(name,script,args,option)
|
|
|
122034
122368
|
case "MULTI_POINT_LINE":
|
|
122035
122369
|
this.CreateLineMultiData(hqChart,windowIndex,item,i);
|
|
122036
122370
|
break;
|
|
122371
|
+
case "DRAW_SIMPLE_TABLE":
|
|
122372
|
+
this.CreateSimpleTable(hqChart,windowIndex,item,i);
|
|
122373
|
+
break;
|
|
122037
122374
|
case "BUY":
|
|
122038
122375
|
case "SELL":
|
|
122039
122376
|
case "SELLSHORT":
|
|
@@ -122381,6 +122718,10 @@ function OverlayScriptIndex(name,script,args,option)
|
|
|
122381
122718
|
this.CreateMulitHtmlDom(hqChart,windowIndex,item,i);
|
|
122382
122719
|
break;
|
|
122383
122720
|
|
|
122721
|
+
case "DRAW_SIMPLE_TABLE":
|
|
122722
|
+
this.CreateSimpleTable(hqChart,windowIndex,item,i);
|
|
122723
|
+
break;
|
|
122724
|
+
|
|
122384
122725
|
case "KLINE_BG":
|
|
122385
122726
|
this.CreateBackgroud(hqChart,windowIndex,item,i);
|
|
122386
122727
|
break;
|
|
@@ -123390,6 +123731,33 @@ function OverlayScriptIndex(name,script,args,option)
|
|
|
123390
123731
|
frame.ChartPaint.push(chart);
|
|
123391
123732
|
}
|
|
123392
123733
|
|
|
123734
|
+
this.CreateSimpleTable=function(hqChart,windowIndex,varItem,i)
|
|
123735
|
+
{
|
|
123736
|
+
var overlayIndex=this.OverlayIndex;
|
|
123737
|
+
var frame=overlayIndex.Frame;
|
|
123738
|
+
var chart=new ChartSimpleTable();
|
|
123739
|
+
chart.Canvas=hqChart.Canvas;
|
|
123740
|
+
chart.Name=varItem.Name;
|
|
123741
|
+
chart.ChartBorder=frame.Frame.ChartBorder;
|
|
123742
|
+
chart.ChartFrame=frame.Frame;
|
|
123743
|
+
chart.Identify=overlayIndex.Identify;
|
|
123744
|
+
chart.HQChart=hqChart;
|
|
123745
|
+
|
|
123746
|
+
if (varItem.Draw && varItem.Draw.DrawData)
|
|
123747
|
+
{
|
|
123748
|
+
var drawData=varItem.Draw.DrawData;
|
|
123749
|
+
if (drawData.TableData) chart.Data.Data=drawData.TableData;
|
|
123750
|
+
if (drawData.BGColor) chart.BGColor=drawData.BGColor;
|
|
123751
|
+
if (drawData.BorderColor) chart.BorderColor=drawData.BorderColor;
|
|
123752
|
+
if (drawData.TextFont) chart.TextFontConfig=drawData.TextFont;
|
|
123753
|
+
if (drawData.TextColor) chart.TextColor=drawData.TextColor;
|
|
123754
|
+
if (IFrameSplitOperator.IsNumber(drawData.XOffset)) chart.Offset.X=drawData.XOffset;
|
|
123755
|
+
if (IFrameSplitOperator.IsNumber(drawData.YOffset)) chart.Offset.Y=drawData.YOffset;
|
|
123756
|
+
}
|
|
123757
|
+
|
|
123758
|
+
frame.ChartPaint.push(chart);
|
|
123759
|
+
}
|
|
123760
|
+
|
|
123393
123761
|
this.CreateChartVericaltLine=function(hqChart,windowIndex,varItem,id)
|
|
123394
123762
|
{
|
|
123395
123763
|
var overlayIndex=this.OverlayIndex;
|
|
@@ -124581,6 +124949,17 @@ function APIScriptIndex(name,script,args,option, isOverlay)
|
|
|
124581
124949
|
|
|
124582
124950
|
result.push(outVarItem);
|
|
124583
124951
|
}
|
|
124952
|
+
else if (draw.DrawType=="DRAW_SIMPLE_TABLE")
|
|
124953
|
+
{
|
|
124954
|
+
drawItem.Name=draw.Name;
|
|
124955
|
+
drawItem.Type=draw.Type;
|
|
124956
|
+
|
|
124957
|
+
drawItem.DrawType=draw.DrawType;
|
|
124958
|
+
drawItem.DrawData=draw.DrawData; //{ TableData:[ [ {AryCell:[{Text:, Color: }]}, ], ], BGColor:, TextFont:{ Size:, Name: } };
|
|
124959
|
+
|
|
124960
|
+
outVarItem.Draw=drawItem;
|
|
124961
|
+
result.push(outVarItem);
|
|
124962
|
+
}
|
|
124584
124963
|
else
|
|
124585
124964
|
{
|
|
124586
124965
|
var find=g_ScriptIndexChartFactory.Get(draw.DrawType); //外部挂接
|
|
@@ -126185,6 +126564,13 @@ function GetBlackStyle()
|
|
|
126185
126564
|
}
|
|
126186
126565
|
},
|
|
126187
126566
|
|
|
126567
|
+
ChartSimpleTable:
|
|
126568
|
+
{
|
|
126569
|
+
TextColor:"rgb(250,250,250)",
|
|
126570
|
+
BGColor:"rgba(0,0,0,0.85)",
|
|
126571
|
+
BorderColor:"rgb(90,90,90)",
|
|
126572
|
+
},
|
|
126573
|
+
|
|
126188
126574
|
ChartDrawVolProfile:
|
|
126189
126575
|
{
|
|
126190
126576
|
BGColor:"rgba(244,250,254,0.3)",
|
|
@@ -140720,7 +141106,7 @@ function ScrollBarBGChart()
|
|
|
140720
141106
|
|
|
140721
141107
|
|
|
140722
141108
|
|
|
140723
|
-
var HQCHART_VERSION="1.1.
|
|
141109
|
+
var HQCHART_VERSION="1.1.14285";
|
|
140724
141110
|
|
|
140725
141111
|
function PrintHQChartVersion()
|
|
140726
141112
|
{
|