support pageOrder
This commit is contained in:
parent
2f3865addc
commit
b721c16335
@ -14,6 +14,7 @@ class ref_builder_xlsx extends ref_builder {
|
|||||||
"page_size" => "string",
|
"page_size" => "string",
|
||||||
"fit_to_height" => "bool",
|
"fit_to_height" => "bool",
|
||||||
"fit_to_width" => "bool",
|
"fit_to_width" => "bool",
|
||||||
|
"page_order" => "string",
|
||||||
],
|
],
|
||||||
"->setPageMargin" => [
|
"->setPageMargin" => [
|
||||||
PageMargin::class,
|
PageMargin::class,
|
||||||
|
@ -517,6 +517,10 @@ final class FileSystemHelper implements FileSystemWithRootFolderHelperInterface
|
|||||||
$xml .= " paperSize=\"{$pageSetup->paperSize->value}\"";
|
$xml .= " paperSize=\"{$pageSetup->paperSize->value}\"";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (null !== $pageSetup->pageOrder) {
|
||||||
|
$xml .= " pageOrder=\"{$pageSetup->pageOrder->value}\"";
|
||||||
|
}
|
||||||
|
|
||||||
if (null !== $pageSetup->fitToHeight) {
|
if (null !== $pageSetup->fitToHeight) {
|
||||||
$xml .= " fitToHeight=\"{$pageSetup->fitToHeight}\"";
|
$xml .= " fitToHeight=\"{$pageSetup->fitToHeight}\"";
|
||||||
}
|
}
|
||||||
|
11
upstream-4.x/src/Writer/XLSX/Options/PageOrder.php
Normal file
11
upstream-4.x/src/Writer/XLSX/Options/PageOrder.php
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
declare(strict_types=1);
|
||||||
|
|
||||||
|
namespace OpenSpout\Writer\XLSX\Options;
|
||||||
|
|
||||||
|
enum PageOrder: string
|
||||||
|
{
|
||||||
|
case DOWN_THEN_OVER = 'downThenOver';
|
||||||
|
case OVER_THEN_DOWN = 'overThenDown';
|
||||||
|
}
|
@ -13,6 +13,7 @@ final readonly class PageSetup
|
|||||||
public ?PaperSize $paperSize,
|
public ?PaperSize $paperSize,
|
||||||
public ?int $fitToHeight = null,
|
public ?int $fitToHeight = null,
|
||||||
public ?int $fitToWidth = null,
|
public ?int $fitToWidth = null,
|
||||||
|
public ?PageOrder $pageOrder = null,
|
||||||
) {
|
) {
|
||||||
$this->fitToPage = null !== $fitToHeight || null !== $fitToWidth;
|
$this->fitToPage = null !== $fitToHeight || null !== $fitToWidth;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user