Completed
Branch develop (c24f26)
by
unknown
26:13
created
phpoffice/phpspreadsheet/src/PhpSpreadsheet/RichText/TextElement.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@
 block discarded – undo
64 64
     public function getHashCode()
65 65
     {
66 66
         return md5(
67
-            $this->text .
67
+            $this->text.
68 68
             __CLASS__
69 69
         );
70 70
     }
Please login to merge, or discard this patch.
includes/phpoffice/phpspreadsheet/src/PhpSpreadsheet/ReferenceHelper.php 1 patch
Spacing   +52 added lines, -52 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
      */
55 55
     public static function columnSort($a, $b)
56 56
     {
57
-        return strcasecmp(strlen($a) . $a, strlen($b) . $b);
57
+        return strcasecmp(strlen($a).$a, strlen($b).$b);
58 58
     }
59 59
 
60 60
     /**
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
      */
69 69
     public static function columnReverseSort($a, $b)
70 70
     {
71
-        return 1 - strcasecmp(strlen($a) . $a, strlen($b) . $b);
71
+        return 1 - strcasecmp(strlen($a).$a, strlen($b).$b);
72 72
     }
73 73
 
74 74
     /**
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
         [$bc, $br] = sscanf($b, '%[A-Z]%d');
87 87
 
88 88
         if ($ar === $br) {
89
-            return strcasecmp(strlen($ac) . $ac, strlen($bc) . $bc);
89
+            return strcasecmp(strlen($ac).$ac, strlen($bc).$bc);
90 90
         }
91 91
 
92 92
         return ($ar < $br) ? -1 : 1;
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
         [$bc, $br] = sscanf($b, '%[A-Z]%d');
108 108
 
109 109
         if ($ar === $br) {
110
-            return 1 - strcasecmp(strlen($ac) . $ac, strlen($bc) . $bc);
110
+            return 1 - strcasecmp(strlen($ac).$ac, strlen($bc).$bc);
111 111
         }
112 112
 
113 113
         return ($ar < $br) ? 1 : -1;
@@ -312,7 +312,7 @@  discard block
 block discarded – undo
312 312
         $aColumnDimensions = array_reverse($pSheet->getColumnDimensions(), true);
313 313
         if (!empty($aColumnDimensions)) {
314 314
             foreach ($aColumnDimensions as $objColumnDimension) {
315
-                $newReference = $this->updateCellReference($objColumnDimension->getColumnIndex() . '1', $pBefore, $pNumCols, $pNumRows);
315
+                $newReference = $this->updateCellReference($objColumnDimension->getColumnIndex().'1', $pBefore, $pNumCols, $pNumRows);
316 316
                 [$newReference] = Coordinate::coordinateFromString($newReference);
317 317
                 if ($objColumnDimension->getColumnIndex() != $newReference) {
318 318
                     $objColumnDimension->setColumnIndex($newReference);
@@ -337,7 +337,7 @@  discard block
 block discarded – undo
337 337
         $aRowDimensions = array_reverse($pSheet->getRowDimensions(), true);
338 338
         if (!empty($aRowDimensions)) {
339 339
             foreach ($aRowDimensions as $objRowDimension) {
340
-                $newReference = $this->updateCellReference('A' . $objRowDimension->getRowIndex(), $pBefore, $pNumCols, $pNumRows);
340
+                $newReference = $this->updateCellReference('A'.$objRowDimension->getRowIndex(), $pBefore, $pNumCols, $pNumRows);
341 341
                 [, $newReference] = Coordinate::coordinateFromString($newReference);
342 342
                 if ($objRowDimension->getRowIndex() != $newReference) {
343 343
                     $objRowDimension->setRowIndex($newReference);
@@ -383,7 +383,7 @@  discard block
 block discarded – undo
383 383
         if ($pNumCols < 0 && $beforeColumnIndex - 2 + $pNumCols > 0) {
384 384
             for ($i = 1; $i <= $highestRow - 1; ++$i) {
385 385
                 for ($j = $beforeColumnIndex - 1 + $pNumCols; $j <= $beforeColumnIndex - 2; ++$j) {
386
-                    $coordinate = Coordinate::stringFromColumnIndex($j + 1) . $i;
386
+                    $coordinate = Coordinate::stringFromColumnIndex($j + 1).$i;
387 387
                     $pSheet->removeConditionalStyles($coordinate);
388 388
                     if ($pSheet->cellExists($coordinate)) {
389 389
                         $pSheet->getCell($coordinate)->setValueExplicit('', DataType::TYPE_NULL);
@@ -397,7 +397,7 @@  discard block
 block discarded – undo
397 397
         if ($pNumRows < 0 && $beforeRow - 1 + $pNumRows > 0) {
398 398
             for ($i = $beforeColumnIndex - 1; $i <= Coordinate::columnIndexFromString($highestColumn) - 1; ++$i) {
399 399
                 for ($j = $beforeRow + $pNumRows; $j <= $beforeRow - 1; ++$j) {
400
-                    $coordinate = Coordinate::stringFromColumnIndex($i + 1) . $j;
400
+                    $coordinate = Coordinate::stringFromColumnIndex($i + 1).$j;
401 401
                     $pSheet->removeConditionalStyles($coordinate);
402 402
                     if ($pSheet->cellExists($coordinate)) {
403 403
                         $pSheet->getCell($coordinate)->setValueExplicit('', DataType::TYPE_NULL);
@@ -421,7 +421,7 @@  discard block
 block discarded – undo
421 421
             }
422 422
 
423 423
             // New coordinate
424
-            $newCoordinate = Coordinate::stringFromColumnIndex($cellIndex + $pNumCols) . ($cell->getRow() + $pNumRows);
424
+            $newCoordinate = Coordinate::stringFromColumnIndex($cellIndex + $pNumCols).($cell->getRow() + $pNumRows);
425 425
 
426 426
             // Should the cell be updated? Move value and cellXf index from one cell to another.
427 427
             if (($cellIndex >= $beforeColumnIndex) && ($cell->getRow() >= $beforeRow)) {
@@ -457,7 +457,7 @@  discard block
 block discarded – undo
457 457
         if ($pNumCols > 0 && $beforeColumnIndex - 2 > 0) {
458 458
             for ($i = $beforeRow; $i <= $highestRow - 1; ++$i) {
459 459
                 // Style
460
-                $coordinate = Coordinate::stringFromColumnIndex($beforeColumnIndex - 1) . $i;
460
+                $coordinate = Coordinate::stringFromColumnIndex($beforeColumnIndex - 1).$i;
461 461
                 if ($pSheet->cellExists($coordinate)) {
462 462
                     $xfIndex = $pSheet->getCell($coordinate)->getXfIndex();
463 463
                     $conditionalStyles = $pSheet->conditionalStylesExists($coordinate) ?
@@ -469,7 +469,7 @@  discard block
 block discarded – undo
469 469
                             foreach ($conditionalStyles as $conditionalStyle) {
470 470
                                 $cloned[] = clone $conditionalStyle;
471 471
                             }
472
-                            $pSheet->setConditionalStyles(Coordinate::stringFromColumnIndex($j) . $i, $cloned);
472
+                            $pSheet->setConditionalStyles(Coordinate::stringFromColumnIndex($j).$i, $cloned);
473 473
                         }
474 474
                     }
475 475
                 }
@@ -479,19 +479,19 @@  discard block
 block discarded – undo
479 479
         if ($pNumRows > 0 && $beforeRow - 1 > 0) {
480 480
             for ($i = $beforeColumnIndex; $i <= Coordinate::columnIndexFromString($highestColumn); ++$i) {
481 481
                 // Style
482
-                $coordinate = Coordinate::stringFromColumnIndex($i) . ($beforeRow - 1);
482
+                $coordinate = Coordinate::stringFromColumnIndex($i).($beforeRow - 1);
483 483
                 if ($pSheet->cellExists($coordinate)) {
484 484
                     $xfIndex = $pSheet->getCell($coordinate)->getXfIndex();
485 485
                     $conditionalStyles = $pSheet->conditionalStylesExists($coordinate) ?
486 486
                         $pSheet->getConditionalStyles($coordinate) : false;
487 487
                     for ($j = $beforeRow; $j <= $beforeRow - 1 + $pNumRows; ++$j) {
488
-                        $pSheet->getCell(Coordinate::stringFromColumnIndex($i) . $j)->setXfIndex($xfIndex);
488
+                        $pSheet->getCell(Coordinate::stringFromColumnIndex($i).$j)->setXfIndex($xfIndex);
489 489
                         if ($conditionalStyles) {
490 490
                             $cloned = [];
491 491
                             foreach ($conditionalStyles as $conditionalStyle) {
492 492
                                 $cloned[] = clone $conditionalStyle;
493 493
                             }
494
-                            $pSheet->setConditionalStyles(Coordinate::stringFromColumnIndex($i) . $j, $cloned);
494
+                            $pSheet->setConditionalStyles(Coordinate::stringFromColumnIndex($i).$j, $cloned);
495 495
                         }
496 496
                     }
497 497
                 }
@@ -639,102 +639,102 @@  discard block
 block discarded – undo
639 639
                 $adjustCount = 0;
640 640
                 $newCellTokens = $cellTokens = [];
641 641
                 //    Search for row ranges (e.g. 'Sheet1'!3:5 or 3:5) with or without $ absolutes (e.g. $3:5)
642
-                $matchCount = preg_match_all('/' . self::REFHELPER_REGEXP_ROWRANGE . '/i', ' ' . $formulaBlock . ' ', $matches, PREG_SET_ORDER);
642
+                $matchCount = preg_match_all('/'.self::REFHELPER_REGEXP_ROWRANGE.'/i', ' '.$formulaBlock.' ', $matches, PREG_SET_ORDER);
643 643
                 if ($matchCount > 0) {
644 644
                     foreach ($matches as $match) {
645
-                        $fromString = ($match[2] > '') ? $match[2] . '!' : '';
646
-                        $fromString .= $match[3] . ':' . $match[4];
647
-                        $modified3 = substr($this->updateCellReference('$A' . $match[3], $pBefore, $pNumCols, $pNumRows), 2);
648
-                        $modified4 = substr($this->updateCellReference('$A' . $match[4], $pBefore, $pNumCols, $pNumRows), 2);
645
+                        $fromString = ($match[2] > '') ? $match[2].'!' : '';
646
+                        $fromString .= $match[3].':'.$match[4];
647
+                        $modified3 = substr($this->updateCellReference('$A'.$match[3], $pBefore, $pNumCols, $pNumRows), 2);
648
+                        $modified4 = substr($this->updateCellReference('$A'.$match[4], $pBefore, $pNumCols, $pNumRows), 2);
649 649
 
650
-                        if ($match[3] . ':' . $match[4] !== $modified3 . ':' . $modified4) {
650
+                        if ($match[3].':'.$match[4] !== $modified3.':'.$modified4) {
651 651
                             if (($match[2] == '') || (trim($match[2], "'") == $sheetName)) {
652
-                                $toString = ($match[2] > '') ? $match[2] . '!' : '';
653
-                                $toString .= $modified3 . ':' . $modified4;
652
+                                $toString = ($match[2] > '') ? $match[2].'!' : '';
653
+                                $toString .= $modified3.':'.$modified4;
654 654
                                 //    Max worksheet size is 1,048,576 rows by 16,384 columns in Excel 2007, so our adjustments need to be at least one digit more
655 655
                                 $column = 100000;
656 656
                                 $row = 10000000 + trim($match[3], '$');
657
-                                $cellIndex = $column . $row;
657
+                                $cellIndex = $column.$row;
658 658
 
659 659
                                 $newCellTokens[$cellIndex] = preg_quote($toString, '/');
660
-                                $cellTokens[$cellIndex] = '/(?<!\d\$\!)' . preg_quote($fromString, '/') . '(?!\d)/i';
660
+                                $cellTokens[$cellIndex] = '/(?<!\d\$\!)'.preg_quote($fromString, '/').'(?!\d)/i';
661 661
                                 ++$adjustCount;
662 662
                             }
663 663
                         }
664 664
                     }
665 665
                 }
666 666
                 //    Search for column ranges (e.g. 'Sheet1'!C:E or C:E) with or without $ absolutes (e.g. $C:E)
667
-                $matchCount = preg_match_all('/' . self::REFHELPER_REGEXP_COLRANGE . '/i', ' ' . $formulaBlock . ' ', $matches, PREG_SET_ORDER);
667
+                $matchCount = preg_match_all('/'.self::REFHELPER_REGEXP_COLRANGE.'/i', ' '.$formulaBlock.' ', $matches, PREG_SET_ORDER);
668 668
                 if ($matchCount > 0) {
669 669
                     foreach ($matches as $match) {
670
-                        $fromString = ($match[2] > '') ? $match[2] . '!' : '';
671
-                        $fromString .= $match[3] . ':' . $match[4];
672
-                        $modified3 = substr($this->updateCellReference($match[3] . '$1', $pBefore, $pNumCols, $pNumRows), 0, -2);
673
-                        $modified4 = substr($this->updateCellReference($match[4] . '$1', $pBefore, $pNumCols, $pNumRows), 0, -2);
670
+                        $fromString = ($match[2] > '') ? $match[2].'!' : '';
671
+                        $fromString .= $match[3].':'.$match[4];
672
+                        $modified3 = substr($this->updateCellReference($match[3].'$1', $pBefore, $pNumCols, $pNumRows), 0, -2);
673
+                        $modified4 = substr($this->updateCellReference($match[4].'$1', $pBefore, $pNumCols, $pNumRows), 0, -2);
674 674
 
675
-                        if ($match[3] . ':' . $match[4] !== $modified3 . ':' . $modified4) {
675
+                        if ($match[3].':'.$match[4] !== $modified3.':'.$modified4) {
676 676
                             if (($match[2] == '') || (trim($match[2], "'") == $sheetName)) {
677
-                                $toString = ($match[2] > '') ? $match[2] . '!' : '';
678
-                                $toString .= $modified3 . ':' . $modified4;
677
+                                $toString = ($match[2] > '') ? $match[2].'!' : '';
678
+                                $toString .= $modified3.':'.$modified4;
679 679
                                 //    Max worksheet size is 1,048,576 rows by 16,384 columns in Excel 2007, so our adjustments need to be at least one digit more
680 680
                                 $column = Coordinate::columnIndexFromString(trim($match[3], '$')) + 100000;
681 681
                                 $row = 10000000;
682
-                                $cellIndex = $column . $row;
682
+                                $cellIndex = $column.$row;
683 683
 
684 684
                                 $newCellTokens[$cellIndex] = preg_quote($toString, '/');
685
-                                $cellTokens[$cellIndex] = '/(?<![A-Z\$\!])' . preg_quote($fromString, '/') . '(?![A-Z])/i';
685
+                                $cellTokens[$cellIndex] = '/(?<![A-Z\$\!])'.preg_quote($fromString, '/').'(?![A-Z])/i';
686 686
                                 ++$adjustCount;
687 687
                             }
688 688
                         }
689 689
                     }
690 690
                 }
691 691
                 //    Search for cell ranges (e.g. 'Sheet1'!A3:C5 or A3:C5) with or without $ absolutes (e.g. $A1:C$5)
692
-                $matchCount = preg_match_all('/' . self::REFHELPER_REGEXP_CELLRANGE . '/i', ' ' . $formulaBlock . ' ', $matches, PREG_SET_ORDER);
692
+                $matchCount = preg_match_all('/'.self::REFHELPER_REGEXP_CELLRANGE.'/i', ' '.$formulaBlock.' ', $matches, PREG_SET_ORDER);
693 693
                 if ($matchCount > 0) {
694 694
                     foreach ($matches as $match) {
695
-                        $fromString = ($match[2] > '') ? $match[2] . '!' : '';
696
-                        $fromString .= $match[3] . ':' . $match[4];
695
+                        $fromString = ($match[2] > '') ? $match[2].'!' : '';
696
+                        $fromString .= $match[3].':'.$match[4];
697 697
                         $modified3 = $this->updateCellReference($match[3], $pBefore, $pNumCols, $pNumRows);
698 698
                         $modified4 = $this->updateCellReference($match[4], $pBefore, $pNumCols, $pNumRows);
699 699
 
700
-                        if ($match[3] . $match[4] !== $modified3 . $modified4) {
700
+                        if ($match[3].$match[4] !== $modified3.$modified4) {
701 701
                             if (($match[2] == '') || (trim($match[2], "'") == $sheetName)) {
702
-                                $toString = ($match[2] > '') ? $match[2] . '!' : '';
703
-                                $toString .= $modified3 . ':' . $modified4;
702
+                                $toString = ($match[2] > '') ? $match[2].'!' : '';
703
+                                $toString .= $modified3.':'.$modified4;
704 704
                                 [$column, $row] = Coordinate::coordinateFromString($match[3]);
705 705
                                 //    Max worksheet size is 1,048,576 rows by 16,384 columns in Excel 2007, so our adjustments need to be at least one digit more
706 706
                                 $column = Coordinate::columnIndexFromString(trim($column, '$')) + 100000;
707 707
                                 $row = trim($row, '$') + 10000000;
708
-                                $cellIndex = $column . $row;
708
+                                $cellIndex = $column.$row;
709 709
 
710 710
                                 $newCellTokens[$cellIndex] = preg_quote($toString, '/');
711
-                                $cellTokens[$cellIndex] = '/(?<![A-Z]\$\!)' . preg_quote($fromString, '/') . '(?!\d)/i';
711
+                                $cellTokens[$cellIndex] = '/(?<![A-Z]\$\!)'.preg_quote($fromString, '/').'(?!\d)/i';
712 712
                                 ++$adjustCount;
713 713
                             }
714 714
                         }
715 715
                     }
716 716
                 }
717 717
                 //    Search for cell references (e.g. 'Sheet1'!A3 or C5) with or without $ absolutes (e.g. $A1 or C$5)
718
-                $matchCount = preg_match_all('/' . self::REFHELPER_REGEXP_CELLREF . '/i', ' ' . $formulaBlock . ' ', $matches, PREG_SET_ORDER);
718
+                $matchCount = preg_match_all('/'.self::REFHELPER_REGEXP_CELLREF.'/i', ' '.$formulaBlock.' ', $matches, PREG_SET_ORDER);
719 719
 
720 720
                 if ($matchCount > 0) {
721 721
                     foreach ($matches as $match) {
722
-                        $fromString = ($match[2] > '') ? $match[2] . '!' : '';
722
+                        $fromString = ($match[2] > '') ? $match[2].'!' : '';
723 723
                         $fromString .= $match[3];
724 724
 
725 725
                         $modified3 = $this->updateCellReference($match[3], $pBefore, $pNumCols, $pNumRows);
726 726
                         if ($match[3] !== $modified3) {
727 727
                             if (($match[2] == '') || (trim($match[2], "'") == $sheetName)) {
728
-                                $toString = ($match[2] > '') ? $match[2] . '!' : '';
728
+                                $toString = ($match[2] > '') ? $match[2].'!' : '';
729 729
                                 $toString .= $modified3;
730 730
                                 [$column, $row] = Coordinate::coordinateFromString($match[3]);
731 731
                                 //    Max worksheet size is 1,048,576 rows by 16,384 columns in Excel 2007, so our adjustments need to be at least one digit more
732 732
                                 $column = Coordinate::columnIndexFromString(trim($column, '$')) + 100000;
733 733
                                 $row = trim($row, '$') + 10000000;
734
-                                $cellIndex = $row . $column;
734
+                                $cellIndex = $row.$column;
735 735
 
736 736
                                 $newCellTokens[$cellIndex] = preg_quote($toString, '/');
737
-                                $cellTokens[$cellIndex] = '/(?<![A-Z\$\!])' . preg_quote($fromString, '/') . '(?!\d)/i';
737
+                                $cellTokens[$cellIndex] = '/(?<![A-Z\$\!])'.preg_quote($fromString, '/').'(?!\d)/i';
738 738
                                 ++$adjustCount;
739 739
                             }
740 740
                         }
@@ -807,8 +807,8 @@  discard block
 block discarded – undo
807 807
                 if (($cell !== null) && ($cell->getDataType() == DataType::TYPE_FORMULA)) {
808 808
                     $formula = $cell->getValue();
809 809
                     if (strpos($formula, $oldName) !== false) {
810
-                        $formula = str_replace("'" . $oldName . "'!", "'" . $newName . "'!", $formula);
811
-                        $formula = str_replace($oldName . '!', $newName . '!', $formula);
810
+                        $formula = str_replace("'".$oldName."'!", "'".$newName."'!", $formula);
811
+                        $formula = str_replace($oldName.'!', $newName.'!', $formula);
812 812
                         $cell->setValueExplicit($formula, DataType::TYPE_FORMULA);
813 813
                     }
814 814
                 }
@@ -841,10 +841,10 @@  discard block
 block discarded – undo
841 841
             $jc = count($range[$i]);
842 842
             for ($j = 0; $j < $jc; ++$j) {
843 843
                 if (ctype_alpha($range[$i][$j])) {
844
-                    $r = Coordinate::coordinateFromString($this->updateSingleCellReference($range[$i][$j] . '1', $pBefore, $pNumCols, $pNumRows));
844
+                    $r = Coordinate::coordinateFromString($this->updateSingleCellReference($range[$i][$j].'1', $pBefore, $pNumCols, $pNumRows));
845 845
                     $range[$i][$j] = $r[0];
846 846
                 } elseif (ctype_digit($range[$i][$j])) {
847
-                    $r = Coordinate::coordinateFromString($this->updateSingleCellReference('A' . $range[$i][$j], $pBefore, $pNumCols, $pNumRows));
847
+                    $r = Coordinate::coordinateFromString($this->updateSingleCellReference('A'.$range[$i][$j], $pBefore, $pNumCols, $pNumRows));
848 848
                     $range[$i][$j] = $r[1];
849 849
                 } else {
850 850
                     $range[$i][$j] = $this->updateSingleCellReference($range[$i][$j], $pBefore, $pNumCols, $pNumRows);
@@ -895,7 +895,7 @@  discard block
 block discarded – undo
895 895
         }
896 896
 
897 897
         // Return new reference
898
-        return $newColumn . $newRow;
898
+        return $newColumn.$newRow;
899 899
     }
900 900
 
901 901
     /**
Please login to merge, or discard this patch.
includes/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Style/Border.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -231,8 +231,8 @@
 block discarded – undo
231 231
         }
232 232
 
233 233
         return md5(
234
-            $this->borderStyle .
235
-            $this->color->getHashCode() .
234
+            $this->borderStyle.
235
+            $this->color->getHashCode().
236 236
             __CLASS__
237 237
         );
238 238
     }
Please login to merge, or discard this patch.
includes/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Style/Alignment.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -453,13 +453,13 @@
 block discarded – undo
453 453
         }
454 454
 
455 455
         return md5(
456
-            $this->horizontal .
457
-            $this->vertical .
458
-            $this->textRotation .
459
-            ($this->wrapText ? 't' : 'f') .
460
-            ($this->shrinkToFit ? 't' : 'f') .
461
-            $this->indent .
462
-            $this->readOrder .
456
+            $this->horizontal.
457
+            $this->vertical.
458
+            $this->textRotation.
459
+            ($this->wrapText ? 't' : 'f').
460
+            ($this->shrinkToFit ? 't' : 'f').
461
+            $this->indent.
462
+            $this->readOrder.
463 463
             __CLASS__
464 464
         );
465 465
     }
Please login to merge, or discard this patch.
includes/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Style/Conditional.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -248,10 +248,10 @@
 block discarded – undo
248 248
     public function getHashCode()
249 249
     {
250 250
         return md5(
251
-            $this->conditionType .
252
-            $this->operatorType .
253
-            implode(';', $this->condition) .
254
-            $this->style->getHashCode() .
251
+            $this->conditionType.
252
+            $this->operatorType.
253
+            implode(';', $this->condition).
254
+            $this->style->getHashCode().
255 255
             __CLASS__
256 256
         );
257 257
     }
Please login to merge, or discard this patch.
htdocs/includes/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Style/Color.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -187,10 +187,10 @@  discard block
 block discarded – undo
187 187
             $pValue = '000000';
188 188
         }
189 189
         if ($this->isSupervisor) {
190
-            $styleArray = $this->getStyleArray(['argb' => 'FF' . $pValue]);
190
+            $styleArray = $this->getStyleArray(['argb' => 'FF'.$pValue]);
191 191
             $this->getActiveSheet()->getStyle($this->getSelectedCells())->applyFromArray($styleArray);
192 192
         } else {
193
-            $this->argb = 'FF' . $pValue;
193
+            $this->argb = 'FF'.$pValue;
194 194
         }
195 195
 
196 196
         return $this;
@@ -297,12 +297,12 @@  discard block
 block discarded – undo
297 297
         }
298 298
 
299 299
         $rgb = strtoupper(
300
-            str_pad(dechex((int) $red), 2, '0', 0) .
301
-            str_pad(dechex((int) $green), 2, '0', 0) .
300
+            str_pad(dechex((int) $red), 2, '0', 0).
301
+            str_pad(dechex((int) $green), 2, '0', 0).
302 302
             str_pad(dechex((int) $blue), 2, '0', 0)
303 303
         );
304 304
 
305
-        return (($rgba) ? 'FF' : '') . $rgb;
305
+        return (($rgba) ? 'FF' : '').$rgb;
306 306
     }
307 307
 
308 308
     /**
@@ -404,7 +404,7 @@  discard block
 block discarded – undo
404 404
         }
405 405
 
406 406
         return md5(
407
-            $this->argb .
407
+            $this->argb.
408 408
             __CLASS__
409 409
         );
410 410
     }
Please login to merge, or discard this patch.
htdocs/includes/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Style/Style.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -298,7 +298,7 @@  discard block
 block discarded – undo
298 298
                             $rangeStart[1] : $rangeEnd[1] - $yMax + $y;
299 299
 
300 300
                         // build range for region
301
-                        $range = $colStart . $rowStart . ':' . $colEnd . $rowEnd;
301
+                        $range = $colStart.$rowStart.':'.$colEnd.$rowEnd;
302 302
 
303 303
                         // retrieve relevant style array for region
304 304
                         $regionStyles = $pStyles;
@@ -607,14 +607,14 @@  discard block
 block discarded – undo
607 607
         }
608 608
 
609 609
         return md5(
610
-            $this->fill->getHashCode() .
611
-            $this->font->getHashCode() .
612
-            $this->borders->getHashCode() .
613
-            $this->alignment->getHashCode() .
614
-            $this->numberFormat->getHashCode() .
615
-            $hashConditionals .
616
-            $this->protection->getHashCode() .
617
-            ($this->quotePrefix ? 't' : 'f') .
610
+            $this->fill->getHashCode().
611
+            $this->font->getHashCode().
612
+            $this->borders->getHashCode().
613
+            $this->alignment->getHashCode().
614
+            $this->numberFormat->getHashCode().
615
+            $hashConditionals.
616
+            $this->protection->getHashCode().
617
+            ($this->quotePrefix ? 't' : 'f').
618 618
             __CLASS__
619 619
         );
620 620
     }
Please login to merge, or discard this patch.
includes/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Style/NumberFormat.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -386,8 +386,8 @@  discard block
 block discarded – undo
386 386
         }
387 387
 
388 388
         return md5(
389
-            $this->formatCode .
390
-            $this->builtInFormatCode .
389
+            $this->formatCode.
390
+            $this->builtInFormatCode.
391 391
             __CLASS__
392 392
         );
393 393
     }
@@ -463,7 +463,7 @@  discard block
 block discarded – undo
463 463
 
464 464
     private static function escapeQuotesCallback($matches)
465 465
     {
466
-        return '\\' . implode('\\', str_split($matches[1]));
466
+        return '\\'.implode('\\', str_split($matches[1]));
467 467
     }
468 468
 
469 469
     private static function formatAsDate(&$value, &$format)
@@ -511,16 +511,16 @@  discard block
 block discarded – undo
511 511
     private static function formatAsPercentage(&$value, &$format)
512 512
     {
513 513
         if ($format === self::FORMAT_PERCENTAGE) {
514
-            $value = round((100 * $value), 0) . '%';
514
+            $value = round((100 * $value), 0).'%';
515 515
         } else {
516 516
             if (preg_match('/\.[#0]+/', $format, $m)) {
517
-                $s = substr($m[0], 0, 1) . (strlen($m[0]) - 1);
517
+                $s = substr($m[0], 0, 1).(strlen($m[0]) - 1);
518 518
                 $format = str_replace($m[0], $s, $format);
519 519
             }
520 520
             if (preg_match('/^[#0]+/', $format, $m)) {
521 521
                 $format = str_replace($m[0], strlen($m[0]), $format);
522 522
             }
523
-            $format = '%' . str_replace('%', 'f%%', $format);
523
+            $format = '%'.str_replace('%', 'f%%', $format);
524 524
 
525 525
             $value = sprintf($format, 100 * $value);
526 526
         }
@@ -577,12 +577,12 @@  discard block
 block discarded – undo
577 577
             $maskingBlocks = array_reverse($maskingBlocks[0]);
578 578
 
579 579
             foreach ($maskingBlocks as $block) {
580
-                $divisor = 1 . $block[0];
580
+                $divisor = 1.$block[0];
581 581
                 $size = strlen($block[0]);
582 582
                 $offset = $block[1];
583 583
 
584 584
                 $blockValue = sprintf(
585
-                    '%0' . $size . 'd',
585
+                    '%0'.$size.'d',
586 586
                     fmod($number, $divisor)
587 587
                 );
588 588
                 $number = floor($number / $divisor);
@@ -611,12 +611,12 @@  discard block
 block discarded – undo
611 611
             $result1 = self::complexNumberFormatMask($numbers[0], $masks[0], false);
612 612
             $result2 = strrev(self::complexNumberFormatMask(strrev($numbers[1]), strrev($masks[1]), false));
613 613
 
614
-            return (($sign) ? '-' : '') . $result1 . '.' . $result2;
614
+            return (($sign) ? '-' : '').$result1.'.'.$result2;
615 615
         }
616 616
 
617 617
         $result = self::processComplexNumberFormatMask($number, $mask);
618 618
 
619
-        return (($sign) ? '-' : '') . $result;
619
+        return (($sign) ? '-' : '').$result;
620 620
     }
621 621
 
622 622
     private static function formatStraightNumericValue($value, $format, array $matches, $useThousands, $number_regex)
@@ -645,7 +645,7 @@  discard block
 block discarded – undo
645 645
                 }
646 646
                 $value = self::complexNumberFormatMask($value, $format);
647 647
             } else {
648
-                $sprintf_pattern = "%0$minWidth." . strlen($right) . 'f';
648
+                $sprintf_pattern = "%0$minWidth.".strlen($right).'f';
649 649
                 $value = sprintf($sprintf_pattern, $value);
650 650
                 $value = preg_replace($number_regex, $value, $format);
651 651
             }
@@ -657,7 +657,7 @@  discard block
 block discarded – undo
657 657
     private static function formatAsNumber($value, $format)
658 658
     {
659 659
         if ($format === self::FORMAT_CURRENCY_EUR_SIMPLE) {
660
-            return 'EUR ' . sprintf('%1.2f', $value);
660
+            return 'EUR '.sprintf('%1.2f', $value);
661 661
         }
662 662
 
663 663
         // Some non-number strings are quoted, so we'll get rid of the quotes, likewise any positional * symbols
@@ -790,7 +790,7 @@  discard block
 block discarded – undo
790 790
         // Save format with color information for later use below
791 791
         $formatColor = $format;
792 792
         // Strip colour information
793
-        $color_regex = '/\[(' . implode('|', Color::NAMED_COLORS) . ')\]/';
793
+        $color_regex = '/\[('.implode('|', Color::NAMED_COLORS).')\]/';
794 794
         $format = preg_replace($color_regex, '', $format);
795 795
         // Let's begin inspecting the format and converting the value to a formatted string
796 796
 
Please login to merge, or discard this patch.
includes/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Style/Borders.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -411,12 +411,12 @@
 block discarded – undo
411 411
         }
412 412
 
413 413
         return md5(
414
-            $this->getLeft()->getHashCode() .
415
-            $this->getRight()->getHashCode() .
416
-            $this->getTop()->getHashCode() .
417
-            $this->getBottom()->getHashCode() .
418
-            $this->getDiagonal()->getHashCode() .
419
-            $this->getDiagonalDirection() .
414
+            $this->getLeft()->getHashCode().
415
+            $this->getRight()->getHashCode().
416
+            $this->getTop()->getHashCode().
417
+            $this->getBottom()->getHashCode().
418
+            $this->getDiagonal()->getHashCode().
419
+            $this->getDiagonalDirection().
420 420
             __CLASS__
421 421
         );
422 422
     }
Please login to merge, or discard this patch.