Commit da956f60 authored by Ilya.Kirillov's avatar Ilya.Kirillov

Исправлен баг с неправильным добавлением формулы в формулу.

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@59308 954022d7-b5bf-4e40-9824-e11837661b57
parent 50274a4a
...@@ -205,7 +205,7 @@ ParaMath.prototype.Add = function(Item) ...@@ -205,7 +205,7 @@ ParaMath.prototype.Add = function(Item)
var RightRun = Run.Split2(Run.State.ContentPos); var RightRun = Run.Split2(Run.State.ContentPos);
oContent.Internal_Content_Add(StartPos + 1, RightRun, false); oContent.Internal_Content_Add(StartPos + 1, RightRun, false);
oContent.CurPos = StartPos; oContent.CurPos = StartPos + 1;
var lng = oContent.Content.length; var lng = oContent.Content.length;
oContent.Load_FromMenu(Item.Menu, this.Paragraph); oContent.Load_FromMenu(Item.Menu, this.Paragraph);
......
...@@ -2677,7 +2677,8 @@ CMathContent.prototype.private_LoadFromMenuMatrix = function(Type, Pr) ...@@ -2677,7 +2677,8 @@ CMathContent.prototype.private_LoadFromMenuMatrix = function(Type, Pr)
}; };
CMathContent.prototype.Add_Element = function(Element) CMathContent.prototype.Add_Element = function(Element)
{ {
this.Internal_Content_Add(this.Content.length, Element, true); this.Internal_Content_Add(this.CurPos, Element, false);
this.CurPos++;
}; };
CMathContent.prototype.Add_Text = function(sText, MathStyle) CMathContent.prototype.Add_Text = function(sText, MathStyle)
{ {
...@@ -2701,7 +2702,8 @@ CMathContent.prototype.Add_Text = function(sText, MathStyle) ...@@ -2701,7 +2702,8 @@ CMathContent.prototype.Add_Text = function(sText, MathStyle)
if (undefined !== MathStyle && null !== MathStyle) if (undefined !== MathStyle && null !== MathStyle)
MathRun.Math_Apply_Style(MathStyle); MathRun.Math_Apply_Style(MathStyle);
this.Internal_Content_Add(this.Content.length, MathRun, true); this.Internal_Content_Add(this.CurPos, MathRun, false);
this.CurPos++;
} }
}; };
CMathContent.prototype.Add_Symbol = function(Code) CMathContent.prototype.Add_Symbol = function(Code)
...@@ -2712,7 +2714,8 @@ CMathContent.prototype.Add_Symbol = function(Code) ...@@ -2712,7 +2714,8 @@ CMathContent.prototype.Add_Symbol = function(Code)
Symbol.add(Code); Symbol.add(Code);
MathRun.Add(Symbol, true); MathRun.Add(Symbol, true);
this.Internal_Content_Add(this.Content.length, MathRun, true); this.Internal_Content_Add(this.CurPos, MathRun, false);
this.CurPos++;
}; };
CMathContent.prototype.Add_Fraction = function(Pr, NumText, DenText) CMathContent.prototype.Add_Fraction = function(Pr, NumText, DenText)
{ {
......
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