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.
1 parent 0beeb27 commit 3cbc65bCopy full SHA for 3cbc65b
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
*
@@ -41,7 +43,8 @@ public function write()
41
43
}
42
44
$xmlWriter = $this->getXmlWriter();
45
- $zIndices = array(FrameStyle::WRAP_INFRONT => PHP_INT_MAX, FrameStyle::WRAP_BEHIND => -PHP_INT_MAX);
46
+ $maxZIndex = min(PHP_INT_MAX, self::PHP_32BIT_INT_MAX);
47
+ $zIndices = array(FrameStyle::WRAP_INFRONT => $maxZIndex, FrameStyle::WRAP_BEHIND => -$maxZIndex);
48
49
$properties = array(
50
'width' => 'width',
0 commit comments