Merge branch 'issue-49' of krzysiej/paper-pi into master

This commit was merged in pull request #50.
This commit is contained in:
2018-07-29 17:13:20 +02:00
committed by krzysiej

View File

@@ -98,6 +98,18 @@ class HtmlToPos
return $data;
}
/**
* łamie tekst w miejscu spacji do długości 32 znaki na linię
* @param $posText
* @return string
*/
public function textBreak($posText)
{
$posText = wordwrap($posText, 32);
return $posText;
}
public function convert($html = '')
{
$posText = $this->handleNewLine($html);
@@ -107,8 +119,8 @@ class HtmlToPos
$posText = $this->vocabularyWord($posText);
$posText = $this->traficar($posText);
// print_r($posText);
// die();
$posText = $this->textBreak($posText);
return $posText;
}
}