PHPOffice / PHPExcel

ARCHIVED
Other
11.47k stars 4.19k forks source link

setOffsetX not working in Excel #553

Open bastiendonjon opened 9 years ago

bastiendonjon commented 9 years ago

I would like to use setOffsetX to center image in cell.

However, setOffsetX not working when i open my file (2007 Format) with Excel.

It works seamlessly with LivreOffice

$objDrawing = new PHPExcel_Worksheet_Drawing();
$objDrawing->setPath('catalogue/logo_export.jpg');
$objDrawing->setWidth(270);
$objDrawing->setOffsetX(220);
$objDrawing->setCoordinates("A4");
$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());
npap commented 7 years ago

This problem seems that still exists. Is there any other way to center an image in a cell?