From f3fc321177bd780e833dc4c71da3e5793f0e977a Mon Sep 17 00:00:00 2001 From: MarkBaker Date: Sun, 5 Jul 2020 18:32:40 +0200 Subject: [PATCH] Gah! Using PHPStorm refactor changes the formatting, so valid code suddenly triggers in phpcs --- src/PhpSpreadsheet/Reader/Xml/PageSettings.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/PhpSpreadsheet/Reader/Xml/PageSettings.php b/src/PhpSpreadsheet/Reader/Xml/PageSettings.php index d07e55ae..72604dcd 100644 --- a/src/PhpSpreadsheet/Reader/Xml/PageSettings.php +++ b/src/PhpSpreadsheet/Reader/Xml/PageSettings.php @@ -115,16 +115,16 @@ class PageSettings private function setLayout(stdClass $printDefaults, SimpleXMLElement $pageSetupAttributes): void { - $printDefaults->orientation = (string)strtolower($pageSetupAttributes->Orientation) ?: PageSetup::ORIENTATION_PORTRAIT; - $printDefaults->horizontalCentered = (bool)$pageSetupAttributes->CenterHorizontal ?: false; - $printDefaults->verticalCentered = (bool)$pageSetupAttributes->CenterVertical ?: false; + $printDefaults->orientation = (string) strtolower($pageSetupAttributes->Orientation) ?: PageSetup::ORIENTATION_PORTRAIT; + $printDefaults->horizontalCentered = (bool) $pageSetupAttributes->CenterHorizontal ?: false; + $printDefaults->verticalCentered = (bool) $pageSetupAttributes->CenterVertical ?: false; } private function setMargins(stdClass $printDefaults, SimpleXMLElement $pageSetupAttributes): void { - $printDefaults->leftMargin = (float)$pageSetupAttributes->Left ?: 1.0; - $printDefaults->rightMargin = (float)$pageSetupAttributes->Right ?: 1.0; - $printDefaults->topMargin = (float)$pageSetupAttributes->Top ?: 1.0; - $printDefaults->bottomMargin = (float)$pageSetupAttributes->Bottom ?: 1.0; + $printDefaults->leftMargin = (float) $pageSetupAttributes->Left ?: 1.0; + $printDefaults->rightMargin = (float) $pageSetupAttributes->Right ?: 1.0; + $printDefaults->topMargin = (float) $pageSetupAttributes->Top ?: 1.0; + $printDefaults->bottomMargin = (float) $pageSetupAttributes->Bottom ?: 1.0; } }