From 69dc096fe747a87b37093d2a2829ed5e79e9de28 Mon Sep 17 00:00:00 2001 From: Mark Baker Date: Thu, 9 May 2013 22:28:23 +0100 Subject: [PATCH] Added getStyle() method to Cell object --- Classes/PHPExcel/Cell.php | 10 ++++++++++ changelog.txt | 1 + 2 files changed, 11 insertions(+) diff --git a/Classes/PHPExcel/Cell.php b/Classes/PHPExcel/Cell.php index 310680c..9b20b91 100644 --- a/Classes/PHPExcel/Cell.php +++ b/Classes/PHPExcel/Cell.php @@ -486,6 +486,16 @@ class PHPExcel_Cell return $this->_parent->getParent(); } + /** + * Get cell style + * + * @return PHPExcel_Style + */ + public function getStyle() + { + return $this->getWorksheet()->getParent()->getCellXfByIndex($this->getXfIndex()); + } + /** * Re-bind parent * diff --git a/changelog.txt b/changelog.txt index cfe1749..ead60ad 100644 --- a/changelog.txt +++ b/changelog.txt @@ -26,6 +26,7 @@ Fixed in develop branch for release v1.7.9: - Feature: (MBaker) Include charts option for HTML Writer - Feature: (MBaker) Added composer file +- Feature: (MBaker) Added getStyle() method to Cell object - Bugfix: (Asker) Work item 18777 - Error in PHPEXCEL/Calculation.php script on line 2976 (stack pop check) - Bugfix: (MBaker) Work item 18794 - CSV files without a file extension being identified as HTML - Bugfix: (AndreKR) Work item GH-66 - Wrong check for maximum number of rows in Excel5 Writer