@@ -99,7 +99,7 @@ |
||
| 99 | 99 | */ |
| 100 | 100 | public function getDimensionUpperBound() |
| 101 | 101 | { |
| 102 | - return $this->cellBuilder->getCellId($this->maxRowWidth, $this->rowIndex - 1); |
|
| 102 | + return $this->cellBuilder->getCellId($this->maxRowWidth, $this->rowIndex-1); |
|
| 103 | 103 | } |
| 104 | 104 | |
| 105 | 105 | /** |
@@ -149,7 +149,9 @@ |
||
| 149 | 149 | { |
| 150 | 150 | $cellXml = ''; |
| 151 | 151 | foreach (array_values($row) as $cellIndex => $cellValue) { |
| 152 | - if (0 == strlen($cellValue)) continue; |
|
| 152 | + if (0 == strlen($cellValue)) { |
|
| 153 | + continue; |
|
| 154 | + } |
|
| 153 | 155 | if ($this->useCellAutosizing) { |
| 154 | 156 | $this->updateColumnWidths($cellValue, $cellIndex, $style); |
| 155 | 157 | } |
@@ -75,10 +75,10 @@ |
||
| 75 | 75 | public function getCellId($cellNumber, $rowNumber = null) |
| 76 | 76 | { |
| 77 | 77 | if ($cellNumber / 26 < 1) { |
| 78 | - return chr(65 + $cellNumber) . $rowNumber; |
|
| 78 | + return chr(65+$cellNumber) . $rowNumber; |
|
| 79 | 79 | } |
| 80 | 80 | |
| 81 | - return $this->getCellId(floor($cellNumber / 26) - 1) . chr(65 + $cellNumber % 26) . $rowNumber; |
|
| 81 | + return $this->getCellId(floor($cellNumber / 26)-1) . chr(65+$cellNumber % 26) . $rowNumber; |
|
| 82 | 82 | } |
| 83 | 83 | |
| 84 | 84 | /** |
@@ -34,7 +34,7 @@ |
||
| 34 | 34 | { |
| 35 | 35 | foreach (file($csvPath) as $line) { |
| 36 | 36 | $widths = explode(',', trim($line)); |
| 37 | - if (count(range(33, 126)) + 2 == count($widths)) { |
|
| 37 | + if (count(range(33, 126))+2 == count($widths)) { |
|
| 38 | 38 | self::$widths[array_shift($widths)][array_shift($widths)] = |
| 39 | 39 | array_combine(array_map('chr', range(33, 126)), $widths); |
| 40 | 40 | } |
@@ -86,7 +86,7 @@ |
||
| 86 | 86 | $this->sheetFile->fwrite('<cols>'); |
| 87 | 87 | foreach ($this->sheet->getColumnWidths() as $columnNumber => $columnWidth) { |
| 88 | 88 | $this->sheetFile->fwrite( |
| 89 | - sprintf(SheetXml::COLUMN_XML, ($columnNumber + 1), ($columnNumber + 1), |
|
| 89 | + sprintf(SheetXml::COLUMN_XML, ($columnNumber+1), ($columnNumber+1), |
|
| 90 | 90 | $columnWidth) |
| 91 | 91 | ); |
| 92 | 92 | } |