Commit 90ab9782 authored by Ilya Kirillov's avatar Ilya Kirillov

Fixed bug #33746. Also fixed bug with updating hint on a footnote and bug with...

Fixed bug #33746. Also fixed bug with updating hint on a footnote and bug with style of run that contain footnote reference.
parent d403b2ce
...@@ -1853,6 +1853,14 @@ CDocument.prototype.Recalculate = function(bOneParagraph, bRecalcContentLast, _R ...@@ -1853,6 +1853,14 @@ CDocument.prototype.Recalculate = function(bOneParagraph, bRecalcContentLast, _R
this.DrawingDocument.OnEndRecalculate(false, true); this.DrawingDocument.OnEndRecalculate(false, true);
History.Reset_RecalcIndex(); History.Reset_RecalcIndex();
this.private_UpdateCursorXY(true, true); this.private_UpdateCursorXY(true, true);
if (Para.Parent && Para.Parent.Get_TopDocumentContent)
{
var oTopDocument = Para.Parent.Get_TopDocumentContent();
if (oTopDocument instanceof CFootEndnote)
oTopDocument.OnFastRecalculate();
}
return; return;
} }
} }
...@@ -1883,6 +1891,14 @@ CDocument.prototype.Recalculate = function(bOneParagraph, bRecalcContentLast, _R ...@@ -1883,6 +1891,14 @@ CDocument.prototype.Recalculate = function(bOneParagraph, bRecalcContentLast, _R
this.DrawingDocument.OnEndRecalculate(false, true); this.DrawingDocument.OnEndRecalculate(false, true);
History.Reset_RecalcIndex(); History.Reset_RecalcIndex();
this.private_UpdateCursorXY(true, true); this.private_UpdateCursorXY(true, true);
if (SimplePara.Parent && SimplePara.Parent.Get_TopDocumentContent)
{
var oTopDocument = SimplePara.Parent.Get_TopDocumentContent();
if (oTopDocument instanceof CFootEndnote)
oTopDocument.OnFastRecalculate();
}
return; return;
} }
} }
......
...@@ -173,6 +173,10 @@ CFootEndnote.prototype.GetPositionInfo = function() ...@@ -173,6 +173,10 @@ CFootEndnote.prototype.GetPositionInfo = function()
{ {
return this.PositionInfo; return this.PositionInfo;
}; };
CFootEndnote.prototype.OnFastRecalculate = function()
{
this.NeedUpdateHint = true;
};
//--------------------------------------------------------export---------------------------------------------------- //--------------------------------------------------------export----------------------------------------------------
window['AscCommonWord'] = window['AscCommonWord'] || {}; window['AscCommonWord'] = window['AscCommonWord'] || {};
......
...@@ -409,6 +409,7 @@ ParaRun.prototype.Add = function(Item, bMath) ...@@ -409,6 +409,7 @@ ParaRun.prototype.Add = function(Item, bMath)
var NewRun = this.private_SplitRunInCurPos(); var NewRun = this.private_SplitRunInCurPos();
if (NewRun) if (NewRun)
{ {
NewRun.Set_VertAlign(undefined);
NewRun.Set_RStyle(oStyles.GetDefaultFootnoteReference()); NewRun.Set_RStyle(oStyles.GetDefaultFootnoteReference());
NewRun.Cursor_MoveToStartPos(); NewRun.Cursor_MoveToStartPos();
NewRun.Add(Item, bMath); NewRun.Add(Item, bMath);
...@@ -2458,6 +2459,8 @@ ParaRun.prototype.Recalculate_Range = function(PRS, ParaPr, Depth) ...@@ -2458,6 +2459,8 @@ ParaRun.prototype.Recalculate_Range = function(PRS, ParaPr, Depth)
if (para_ContinuationSeparator === ItemType) if (para_ContinuationSeparator === ItemType)
Item.Update_Width(PRS); Item.Update_Width(PRS);
if (true !== PRS.IsFastRecalculate())
{
if (para_FootnoteReference === ItemType) if (para_FootnoteReference === ItemType)
{ {
Item.UpdateNumber(PRS); Item.UpdateNumber(PRS);
...@@ -2467,6 +2470,7 @@ ParaRun.prototype.Recalculate_Range = function(PRS, ParaPr, Depth) ...@@ -2467,6 +2470,7 @@ ParaRun.prototype.Recalculate_Range = function(PRS, ParaPr, Depth)
{ {
Item.UpdateNumber(PRS.TopDocument); Item.UpdateNumber(PRS.TopDocument);
} }
}
// При проверке, убирается ли слово, мы должны учитывать ширину предшествующих пробелов. // При проверке, убирается ли слово, мы должны учитывать ширину предшествующих пробелов.
var LetterLen = Item.Width / TEXTWIDTH_DIVIDER;//var LetterLen = Item.Get_Width(); var LetterLen = Item.Width / TEXTWIDTH_DIVIDER;//var LetterLen = Item.Get_Width();
......
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