Commit a71bdd69 authored by Sergey.Luzyanin's avatar Sergey.Luzyanin Committed by Alexander.Trofimov

Правки багов с диаграммами

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@55683 954022d7-b5bf-4e40-9824-e11837661b57
parent acfe69a3
This diff is collapsed.
......@@ -1241,17 +1241,42 @@ CChartSpace.prototype =
//расчитаем подписи для горизонтальной оси
var ser = chart_object.series[0];
var string_pts = [], pts_len = 0;
/*string_pts pts_len*/
if(ser && ser.cat)
{
var lit;
if(ser.cat.strRef && ser.cat.strRef.strCache)
{
string_pts = ser.cat.strRef.strCache.pt;
pts_len = string_pts.length;
lit = ser.cat.strRef.strCache;
}
else if(ser.cat.strLit)
{
string_pts = ser.cat.strLit.pt;
pts_len = string_pts.length;
lit = ser.cat.strLit;
}
else if(ser.cat.numRef && ser.cat.numRef.numCache)
{
lit = ser.cat.numRef.numCache;
}
else if(ser.cat.numLit)
{
lit = ser.cat.numLit;
}
if(lit)
{
pts_len = lit.ptCount;
for(i = 0; i < pts_len; ++i)
{
var pt = lit.getPtByIndex(i);
if(pt)
{
string_pts.push({val: pt.val + ""});
}
else
{
string_pts.push({val: i + ""});
}
}
}
}
if(string_pts.length === 0)
......@@ -1260,15 +1285,16 @@ CChartSpace.prototype =
for(i = 0; i < chart_object.series.length; ++i)
{
var cur_pts= null;
ser = chart_object.series[i];
if(ser.val)
{
if(ser.val.numRef && ser.val.numRef.numCache)
cur_pts = ser.val.numRef.numCache.pts;
cur_pts = ser.val.numRef.numCache;
else if(ser.val.numLit)
cur_pts = ser.val.numLit.pts;
cur_pts = ser.val.numLit;
if(cur_pts)
{
pts_len = Math.max(pts_len, getMaxIdx(cur_pts));
pts_len = Math.max(pts_len, cur_pts.ptCount);
}
}
}
......@@ -4689,7 +4715,7 @@ CChartSpace.prototype =
{
compiled_marker.setSpPr(new CSpPr());
}
compiled_marker.spPr.setFill(brushes[i]);
compiled_marker.spPr.setFill(brushes[pts[i].idx]);
compiled_marker.spPr.Fill.merge(pts[i].brush);
if(!compiled_marker.spPr.ln)
compiled_marker.spPr.setLn(new CLn());
......@@ -4765,11 +4791,11 @@ CChartSpace.prototype =
{
compiled_marker.setSpPr(new CSpPr());
}
compiled_marker.spPr.setFill(brushes[i]);
compiled_marker.spPr.setFill(brushes[series[i].idx]);
if(!compiled_marker.spPr.ln)
compiled_marker.spPr.setLn(new CLn());
compiled_marker.spPr.ln.setFill(pens_fills[i]);
compiled_marker.setSymbol(GetTypeMarkerByIndex(i));
compiled_marker.spPr.ln.setFill(pens_fills[series[i].idx]);
compiled_marker.setSymbol(GetTypeMarkerByIndex(series[i].idx));
compiled_marker.merge(ser.marker);
if(j === 0)
ser.compiledSeriesMarker = compiled_marker.createDuplicate();
......@@ -6949,7 +6975,6 @@ function CreateLineChart(asc_chart, type)
var title = plot_area.valAx.title;
title.setTxPr(new CTextBody());
title.txPr.setBodyPr(new CBodyPr());
title.txPr.bodyPr.setVert(nVertTTvert);
var line_chart = plot_area.charts[0];
line_chart.setGrouping(type);
line_chart.setVaryColors(false);
......@@ -7657,11 +7682,12 @@ function CreateScatterChart(asc_chart)
var first_series = asc_series.length > 1 ? asc_series[0] : null;
var start_index = asc_series.length > 1 ? 1 : 0;
var parsedHeaders = asc_chart.parseSeriesHeaders();
var minus = start_index === 1 ? 1 : 0;
for(var i = start_index; i < asc_series.length; ++i)
{
var series = new CScatterSeries();
series.setIdx(i);
series.setOrder(i);
series.setIdx(i - minus);
series.setOrder(i - minus);
if(first_series)
{
series.setXVal(new CXVal());
......
......@@ -639,6 +639,53 @@ var historyitem_GraphicObjectsRemoveHeaderOrFooter = 2606;
var historyitem_WrapPolygonSetEdited = 2607;
var historyitem_WrapPolygonSetRelPoints = 2608;
var historyitem_DateAxAuto = 2609;
var historyitem_DateAxAxId = 2610;
var historyitem_DateAxAxPos = 2611;
var historyitem_DateAxBaseTimeUnit = 2612;
var historyitem_DateAxCrossAx = 2613;
var historyitem_DateAxCrosses = 2614;
var historyitem_DateAxCrossesAt = 2615;
var historyitem_DateAxDelete = 2616;
var historyitem_DateAxLblOffset = 2617;
var historyitem_DateAxMajorGridlines = 2618;
var historyitem_DateAxMajorTickMark = 2619;
var historyitem_DateAxMajorTimeUnit = 2620;
var historyitem_DateAxMajorUnit = 2621;
var historyitem_DateAxMinorGridlines = 2622;
var historyitem_DateAxMinorTickMark = 2623;
var historyitem_DateAxMinorTimeUnit = 2624;
var historyitem_DateAxMinorUnit = 2625;
var historyitem_DateAxNumFmt = 2626;
var historyitem_DateAxScaling = 2627;
var historyitem_DateAxSpPr = 2628;
var historyitem_DateAxTickLblPos = 2629;
var historyitem_DateAxTitle = 2630;
var historyitem_DateAxTxPr = 2631;
var historyitem_SerAxSetAxId = 2632;
var historyitem_SerAxSetAxPos = 2633;
var historyitem_SerAxSetCrossAx = 2634;
var historyitem_SerAxSetCrosses = 2635;
var historyitem_SerAxSetCrossesAt = 2636;
var historyitem_SerAxSetDelete = 2637;
var historyitem_SerAxSetMajorGridlines = 2638;
var historyitem_SerAxSetMajorTickMark = 2639;
var historyitem_SerAxSetMinorGridlines = 2640;
var historyitem_SerAxSetMinorTickMark = 2641;
var historyitem_SerAxSetNumFmt = 2642;
var historyitem_SerAxSetScaling = 2643;
var historyitem_SerAxSetSpPr = 2644;
var historyitem_SerAxSetTickLblPos = 2645;
var historyitem_SerAxSetTickLblSkip = 2646;
var historyitem_SerAxSetTickMarkSkip = 2647;
var historyitem_SerAxSetTitle = 2648;
var historyitem_SerAxSetTxPr = 2649;
var historyitem_type_ColorMod = 1001;
var historyitem_type_ColorModifiers = 1002;
var historyitem_type_SysColor = 1003;
......@@ -752,6 +799,8 @@ var historyitem_type_TextBody = 1109;
var historyitem_type_CatAx = 1110;
var historyitem_type_ValAx = 1111;
var historyitem_type_WrapPolygon = 1112;
var historyitem_type_DateAx = 1113;
var historyitem_type_SerAx = 1114;
......
......@@ -10235,7 +10235,7 @@ BinaryChartReader.prototype.ReadCT_PlotArea = function (type, length, val, oIdTo
val.addAxis(oNewVal);
}
else if (c_oserct_plotareaDATEAX === type) {
var oNewVal = new CCatAx();
var oNewVal = new CDateAx();
res = this.bcr.Read1(length, function (t, l) {
return oThis.ReadCT_DateAx(t, l, oNewVal);
});
......@@ -10244,7 +10244,7 @@ BinaryChartReader.prototype.ReadCT_PlotArea = function (type, length, val, oIdTo
val.addAxis(oNewVal);
}
else if (c_oserct_plotareaSERAX === type) {
var oNewVal = new CCatAx();
var oNewVal = new CSerAx();
res = this.bcr.Read1(length, function (t, l) {
return oThis.ReadCT_SerAx(t, l, oNewVal);
});
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment