We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents b926eec + f4697ab commit 835aa9cCopy full SHA for 835aa9c
src/PhpWord/Writer/Word2007/Style/Frame.php
@@ -28,6 +28,8 @@
28
*/
29
class Frame extends AbstractStyle
30
{
31
+ const PHP_32BIT_INT_MAX = 2147483647;
32
+
33
/**
34
* Write style.
35
@@ -39,7 +41,8 @@ public function write()
39
41
}
40
42
$xmlWriter = $this->getXmlWriter();
43
- $zIndices = array(FrameStyle::WRAP_INFRONT => PHP_INT_MAX, FrameStyle::WRAP_BEHIND => -PHP_INT_MAX);
44
+ $maxZIndex = min(PHP_INT_MAX, self::PHP_32BIT_INT_MAX);
45
+ $zIndices = array(FrameStyle::WRAP_INFRONT => $maxZIndex, FrameStyle::WRAP_BEHIND => -$maxZIndex);
46
47
$properties = array(
48
'width' => 'width',
0 commit comments