Commit 8407551c authored by Anna.Pavlova's avatar Anna.Pavlova Committed by Alexander.Trofimov

Поправила расположение и ширину подсветки для EqArray

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@61749 954022d7-b5bf-4e40-9824-e11837661b57
parent b51e77e4
...@@ -1854,6 +1854,8 @@ CMathBase.prototype.Recalculate_Range = function(PRS, ParaPr, Depth) ...@@ -1854,6 +1854,8 @@ CMathBase.prototype.Recalculate_Range = function(PRS, ParaPr, Depth)
this.recalculateSize(g_oTextMeasurer); this.recalculateSize(g_oTextMeasurer);
this.Update_WordLen(PRS, WordLen); this.Update_WordLen(PRS, WordLen);
this.Bounds.SetWidth(0, this.size.width);
this.Bounds.UpdateMetrics(0, this.size);
} }
else else
{ {
......
...@@ -35,7 +35,7 @@ CRPI.prototype.MergeMathInfo = function(MathInfo) ...@@ -35,7 +35,7 @@ CRPI.prototype.MergeMathInfo = function(MathInfo)
this.NeedResize = MathInfo.NeedResize; this.NeedResize = MathInfo.NeedResize;
this.bRecalcCtrPrp = MathInfo.bRecalcCtrPrp; this.bRecalcCtrPrp = MathInfo.bRecalcCtrPrp;
this.bChangeInline = MathInfo.bChangeInline; this.bChangeInline = MathInfo.bChangeInline;
} };
function CMathPointInfo() function CMathPointInfo()
{ {
...@@ -53,7 +53,7 @@ CMathPointInfo.prototype.SetInfoPoints = function(InfoPoints) ...@@ -53,7 +53,7 @@ CMathPointInfo.prototype.SetInfoPoints = function(InfoPoints)
this.InfoPoints.GPoints = InfoPoints.GPoints; this.InfoPoints.GPoints = InfoPoints.GPoints;
this.InfoPoints.ContentPoints = InfoPoints.ContentPoints.Widths; this.InfoPoints.ContentPoints = InfoPoints.ContentPoints.Widths;
this.InfoPoints.GMaxDimWidths = InfoPoints.GMaxDimWidths; this.InfoPoints.GMaxDimWidths = InfoPoints.GMaxDimWidths;
} };
CMathPointInfo.prototype.NextAlignRange = function() CMathPointInfo.prototype.NextAlignRange = function()
{ {
if(this.bEven) if(this.bEven)
...@@ -63,7 +63,7 @@ CMathPointInfo.prototype.NextAlignRange = function() ...@@ -63,7 +63,7 @@ CMathPointInfo.prototype.NextAlignRange = function()
this.CurrPoint++; this.CurrPoint++;
this.bEven = true; this.bEven = true;
} }
} };
CMathPointInfo.prototype.GetAlign = function() CMathPointInfo.prototype.GetAlign = function()
{ {
var align = 0; var align = 0;
...@@ -107,7 +107,7 @@ CMathPointInfo.prototype.GetAlign = function() ...@@ -107,7 +107,7 @@ CMathPointInfo.prototype.GetAlign = function()
} }
return align; return align;
} };
function CInfoPoints() function CInfoPoints()
{ {
...@@ -122,7 +122,7 @@ CInfoPoints.prototype.SetDefault = function() ...@@ -122,7 +122,7 @@ CInfoPoints.prototype.SetDefault = function()
this.GPoints = null; this.GPoints = null;
this.GMaxDimWidths = null; this.GMaxDimWidths = null;
this.ContentPoints.SetDefault(); this.ContentPoints.SetDefault();
} };
function CMathPosition() function CMathPosition()
...@@ -155,7 +155,7 @@ AmperWidths.prototype.UpdatePoint = function(value) ...@@ -155,7 +155,7 @@ AmperWidths.prototype.UpdatePoint = function(value)
this.Widths[len-1].odd += value; this.Widths[len-1].odd += value;
} }
} };
AmperWidths.prototype.AddNewAlignRange = function() AmperWidths.prototype.AddNewAlignRange = function()
{ {
var len = this.Widths.length; var len = this.Widths.length;
...@@ -176,12 +176,12 @@ AmperWidths.prototype.AddNewAlignRange = function() ...@@ -176,12 +176,12 @@ AmperWidths.prototype.AddNewAlignRange = function()
this.bEven = !this.bEven; this.bEven = !this.bEven;
} };
AmperWidths.prototype.SetDefault = function() AmperWidths.prototype.SetDefault = function()
{ {
this.bEven = true; this.bEven = true;
this.Widths.length = 0; this.Widths.length = 0;
} };
function CGaps(oSign, oEqual, oZeroOper, oLett) function CGaps(oSign, oEqual, oZeroOper, oLett)
...@@ -284,7 +284,7 @@ CCoeffGaps.prototype = ...@@ -284,7 +284,7 @@ CCoeffGaps.prototype =
return bOper || bLeftBracket || bRightBracket; return bOper || bLeftBracket || bRightBracket;
} }
} };
var COEFF_GAPS = new CCoeffGaps(); var COEFF_GAPS = new CCoeffGaps();
...@@ -341,7 +341,7 @@ CMathArgSize.prototype = ...@@ -341,7 +341,7 @@ CMathArgSize.prototype =
this.SetValue(this.value + ArgSize.value); this.SetValue(this.value + ArgSize.value);
} }
} };
function CMathGapsInfo(argSize) function CMathGapsInfo(argSize)
{ {
...@@ -499,7 +499,7 @@ CMathGapsInfo.prototype = ...@@ -499,7 +499,7 @@ CMathGapsInfo.prototype =
return {bEmptyGaps: bEmptyGaps, bChildGaps: bChildGaps}; return {bEmptyGaps: bEmptyGaps, bChildGaps: bChildGaps};
} }
} };
function CMPrp() function CMPrp()
{ {
...@@ -622,7 +622,7 @@ CMPrp.prototype = ...@@ -622,7 +622,7 @@ CMPrp.prototype =
return Object; return Object;
} }
} };
...@@ -962,6 +962,7 @@ CMathContent.prototype.ApplyPoints = function(WidthsPoints, Points, MaxDimWidths ...@@ -962,6 +962,7 @@ CMathContent.prototype.ApplyPoints = function(WidthsPoints, Points, MaxDimWidths
this.size.width += this.Content[i].size.width; this.size.width += this.Content[i].size.width;
} }
this.Bounds.SetWidth(0, this.size.width);
}; };
CMathContent.prototype.setPosition = function(pos, PRSA, Line, Range, Page) CMathContent.prototype.setPosition = function(pos, PRSA, Line, Range, Page)
{ {
...@@ -971,9 +972,6 @@ CMathContent.prototype.setPosition = function(pos, PRSA, Line, Range, Page) ...@@ -971,9 +972,6 @@ CMathContent.prototype.setPosition = function(pos, PRSA, Line, Range, Page)
var CurLine = Line - this.StartLine; var CurLine = Line - this.StartLine;
var CurRange = ( 0 === CurLine ? Range - this.StartRange : Range ); var CurRange = ( 0 === CurLine ? Range - this.StartRange : Range );
this.Bounds.SetPos(CurLine, this.pos, PRSA);
this.Bounds.SetPage(CurLine, Page);
var StartPos = this.protected_GetRangeStartPos(CurLine, CurRange); var StartPos = this.protected_GetRangeStartPos(CurLine, CurRange);
var EndPos = this.protected_GetRangeEndPos(CurLine, CurRange); var EndPos = this.protected_GetRangeEndPos(CurLine, CurRange);
...@@ -986,6 +984,9 @@ CMathContent.prototype.setPosition = function(pos, PRSA, Line, Range, Page) ...@@ -986,6 +984,9 @@ CMathContent.prototype.setPosition = function(pos, PRSA, Line, Range, Page)
this.pos.x = pos.x; this.pos.x = pos.x;
} }
this.Bounds.SetPos(CurLine, this.pos, PRSA);
this.Bounds.SetPage(CurLine, Page);
for(var i = StartPos; i <= EndPos; i++) for(var i = StartPos; i <= EndPos; i++)
{ {
if(this.Content[i].Type == para_Math_Run) if(this.Content[i].Type == para_Math_Run)
......
...@@ -118,9 +118,6 @@ var ACCENT_TEXT = 46; ...@@ -118,9 +118,6 @@ var ACCENT_TEXT = 46;
/////////////////////////////////////////////////// ///////////////////////////////////////////////////
/*var TXT_NORMAL = 0;
var TXT_PLAIN = 1;*/
var TXT_ROMAN = 0; // math roman var TXT_ROMAN = 0; // math roman
var TXT_SCRIPT = 1; var TXT_SCRIPT = 1;
......
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