Commit a35046e9 authored by Dmitry.Vikulov's avatar Dmitry.Vikulov Committed by Alexander.Trofimov

Сохранение диагрвмм в pdf(Bug 21291)

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@50867 954022d7-b5bf-4e40-9824-e11837661b57
parent 957dab9f
......@@ -3325,8 +3325,31 @@ function DrawingObjects() {
var ty = drawingObject.graphicObject.transform.ty;
drawingObject.graphicObject.transform.tx -= left;
drawingObject.graphicObject.transform.ty -= top;
// Save chart transforms
var chartTxtAreas = [];
var aTxtTransform = [];
if ( drawingObject.graphicObject instanceof CChartAsGroup ) {
chartTxtAreas = [ drawingObject.graphicObject.chartTitle, drawingObject.graphicObject.vAxisTitle, drawingObject.graphicObject.hAxisTitle ];
for ( var n = 0; n < chartTxtAreas.length; n++ ) {
var item = chartTxtAreas[n];
aTxtTransform.push( { tx: item.transformText.tx, ty: item.transformText.ty } );
item.transformText.tx -= left;
item.transformText.ty -= top;
}
}
drawingObject.graphicObject.draw( printOptions.ctx.DocumentRenderer );
// Restore chart transforms
if ( drawingObject.graphicObject instanceof CChartAsGroup ) {
for ( var n = 0; n < chartTxtAreas.length; n++ ) {
var item = chartTxtAreas[n];
item.transformText.tx = aTxtTransform[n].tx;
item.transformText.ty = aTxtTransform[n].ty;
}
}
// Restore
drawingObject.graphicObject.transform.tx = tx;
drawingObject.graphicObject.transform.ty = ty;
......
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