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

Поправлено падение при применении текстовых свойста ко всей диаграмме

parent aac031be
...@@ -1382,7 +1382,7 @@ DrawingObjectsController.prototype = ...@@ -1382,7 +1382,7 @@ DrawingObjectsController.prototype =
{ {
if(f === CDocumentContent.prototype.Paragraph_Add && args[0].Type === para_TextPr) if(f === CDocumentContent.prototype.Paragraph_Add && args[0].Type === para_TextPr)
{ {
CheckObjectTextPr(arr[i], args[0].Value, oThis.getDrawingDocument()); AscFormat.CheckObjectTextPr(arr[i], args[0].Value, oThis.getDrawingDocument());
} }
if(f === CDocumentContent.prototype.Paragraph_IncDecFontSize) if(f === CDocumentContent.prototype.Paragraph_IncDecFontSize)
{ {
...@@ -2539,6 +2539,7 @@ DrawingObjectsController.prototype = ...@@ -2539,6 +2539,7 @@ DrawingObjectsController.prototype =
var style_index = chartSettings.getStyle(); var style_index = chartSettings.getStyle();
var sRange = chartSettings.getRange(); var sRange = chartSettings.getRange();
var b_clear_formatting = false; var b_clear_formatting = false;
chartSpace.resetSelection(true);
if(this.drawingObjects && this.drawingObjects.getWorksheet && typeof sRange === "string" && sRange.length > 0) if(this.drawingObjects && this.drawingObjects.getWorksheet && typeof sRange === "string" && sRange.length > 0)
{ {
var ws_view = this.drawingObjects.getWorksheet(); var ws_view = this.drawingObjects.getWorksheet();
......
...@@ -465,8 +465,15 @@ function CheckIncDecFontSize(oElement, bIncrease, oDrawingDocument,nDefaultSize) ...@@ -465,8 +465,15 @@ function CheckIncDecFontSize(oElement, bIncrease, oDrawingDocument,nDefaultSize)
oCopyTextPr.FontSize = FontSize_IncreaseDecreaseValue( bIncrease, isRealNumber(oCopyTextPr.FontSize) ? oCopyTextPr.FontSize : nDefaultSize); oCopyTextPr.FontSize = FontSize_IncreaseDecreaseValue( bIncrease, isRealNumber(oCopyTextPr.FontSize) ? oCopyTextPr.FontSize : nDefaultSize);
oParaPr.DefaultRunPr = oCopyTextPr; oParaPr.DefaultRunPr = oCopyTextPr;
oElement.txPr.content.Content[0].Set_Pr(oParaPr); oElement.txPr.content.Content[0].Set_Pr(oParaPr);
if(oElement.tx && oElement.tx.rich)
{
oElement.tx.rich.content.Set_ApplyToAll(true);
oElement.tx.rich.content.Paragraph_IncDecFontSize(bIncrease);
oElement.tx.rich.content.Set_ApplyToAll(false);
}
}
} }
}
function CChartSpace() function CChartSpace()
{ {
...@@ -12602,4 +12609,5 @@ function checkBlipFillRasterImages(sp) ...@@ -12602,4 +12609,5 @@ function checkBlipFillRasterImages(sp)
window['AscFormat'].initStyleManager = initStyleManager; window['AscFormat'].initStyleManager = initStyleManager;
window['AscFormat'].CheckParagraphTextPr = CheckParagraphTextPr; window['AscFormat'].CheckParagraphTextPr = CheckParagraphTextPr;
window['AscFormat'].CheckObjectTextPr = CheckObjectTextPr;
})(window); })(window);
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