Merge pull request #15635 from owncloud/issue/15634-empty-txt-previews

Scale up the font on larger previews
This commit is contained in:
Morris Jobke 2015-04-20 15:55:32 +02:00
commit 3e8f6cdba9

View file

@ -55,7 +55,7 @@ class TXT extends Provider {
$lines = preg_split("/\r\n|\n|\r/", $content);
$fontSize = 5; //5px
$fontSize = ($maxX) ? (int) ((5 / 36) * $maxX) : 5; //5px
$lineSize = ceil($fontSize * 1.25);
$image = imagecreate($maxX, $maxY);