Not sure why array_item() was being called with a $key of true, but it was resulting in a "method call on a non-object" error with gradient fills.
git-svn-id: https://phpexcel.svn.codeplex.com/svn/trunk@69199 2327b42d-5241-43d6-9e2a-de5ac946f064
This commit is contained in:
parent
57f3b411d1
commit
bba779bfc3
|
@ -1573,8 +1573,8 @@ class PHPExcel_Reader_Excel2007 implements PHPExcel_Reader_IReader
|
|||
}
|
||||
$docStyle->getFill()->setRotation(floatval($gradientFill["degree"]));
|
||||
$gradientFill->registerXPathNamespace("sml", "http://schemas.openxmlformats.org/spreadsheetml/2006/main");
|
||||
$docStyle->getFill()->getStartColor()->setARGB(self::_readColor( self::array_item($gradientFill->xpath("sml:stop[@position=0]"),true)->color) );
|
||||
$docStyle->getFill()->getEndColor()->setARGB(self::_readColor( self::array_item($gradientFill->xpath("sml:stop[@position=1]"),true)->color) );
|
||||
$docStyle->getFill()->getStartColor()->setARGB(self::_readColor( self::array_item($gradientFill->xpath("sml:stop[@position=0]"))->color) );
|
||||
$docStyle->getFill()->getEndColor()->setARGB(self::_readColor( self::array_item($gradientFill->xpath("sml:stop[@position=1]"))->color) );
|
||||
} elseif ($style->fill->patternFill) {
|
||||
$patternType = (string)$style->fill->patternFill["patternType"] != '' ? (string)$style->fill->patternFill["patternType"] : 'solid';
|
||||
$docStyle->getFill()->setFillType($patternType);
|
||||
|
|
Loading…
Reference in New Issue