Reduce text size of text file preview, fix #13720
Signed-off-by: Jan-Christoph Borchardt <hey@jancborchardt.net>
This commit is contained in:
parent
68c0fd3863
commit
9147a12ee1
|
@ -60,8 +60,9 @@ class TXT extends Provider {
|
||||||
|
|
||||||
$lines = preg_split("/\r\n|\n|\r/", $content);
|
$lines = preg_split("/\r\n|\n|\r/", $content);
|
||||||
|
|
||||||
$fontSize = $maxX ? (int) ((5 / 32) * $maxX) : 5; //5px
|
// Define text size of text file preview
|
||||||
$lineSize = ceil($fontSize * 1.25);
|
$fontSize = $maxX ? (int) ((2 / 32) * $maxX) : 5; //5px
|
||||||
|
$lineSize = ceil($fontSize * 1.5);
|
||||||
|
|
||||||
$image = imagecreate($maxX, $maxY);
|
$image = imagecreate($maxX, $maxY);
|
||||||
imagecolorallocate($image, 255, 255, 255);
|
imagecolorallocate($image, 255, 255, 255);
|
||||||
|
|
Loading…
Reference in New Issue