We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9d9eb59 commit 02badabCopy full SHA for 02badab
Image/Canvas/SVG.php
@@ -740,7 +740,8 @@ function addText($params)
740
741
$attrs = (isset($params['attrs']) && is_array($params['attrs'])) ? $this->_getAttributes($params['attrs']) : null;
742
743
- $textHeight = $this->textHeight($text);
+ $lines = explode("\n", $text);
744
+ $textHeight = $this->textHeight($lines[0]);
745
746
if (!is_array($alignment)) {
747
$alignment = array('vertical' => 'top', 'horizontal' => 'left');
0 commit comments