Commit 9029acfd authored by Sergey.Konovalov's avatar Sergey.Konovalov Committed by Alexander.Trofimov

для mailmerge: при сохранении формул в html заменяем их картинками

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@62744 954022d7-b5bf-4e40-9824-e11837661b57
parent edd18005
......@@ -3652,7 +3652,27 @@ function BinaryDocumentTableWriter(memory, doc, oMapCommentId, oNumIdMap, copyPa
case para_Math:
{
if (null != item.Root)
this.bs.WriteItem(c_oSerParType.OMathPara, function(){oThis.boMaths.WriteOMathPara(item);});
{
if(this.saveParams && this.saveParams.bMailMergeHtml)
{
//заменяем на картинку, если бы был аналог CachedImage не надо было бы заменять
var sSrc = item.MathToImageConverter();
if (null != sSrc && "" != sSrc && null != sSrc.ImageUrl && item.Width > 0 && item.Height > 0){
var doc = this.Document;
//todo paragraph
var drawing = new ParaDrawing(item.Width, item.Height, null, this.Document.DrawingDocument, this.Document, par);
var Image = editor.WordControl.m_oLogicDocument.DrawingObjects.createImage(sSrc.ImageUrl, 0, 0, item.Width, item.Height);
Image.cachedImage = sSrc.ImageUrl;
drawing.Set_GraphicObject(Image);
Image.setParent(drawing);
this.WriteRun2( function () {
oThis.bs.WriteItem(c_oSerRunType.pptxDrawing, function () { oThis.WriteImage(drawing); });
});
}
}
else
this.bs.WriteItem(c_oSerParType.OMathPara, function(){oThis.boMaths.WriteOMathPara(item);});
}
}
break;
......
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