Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2020-01-14 16:21:12 +0300
committernpmbuildbot[bot] <npmbuildbot[bot]@users.noreply.github.com>2020-01-15 01:38:04 +0300
commit17256781a6900f45ddcb1be2f67f627072e33586 (patch)
tree973cbc2fc72302c65ddcb4860d2458c79a0ddd20 /lib
parent092a1fb90f57639a15adc5a8e565b53debe26a8a (diff)
Proper text previews
Fixes #17828 * Modified the preview provider to provider smaller fonts for the previes (so it is not so screaming) * Modified the sidebar to show plain text and markdown files full size. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl> Signed-off-by: npmbuildbot[bot] <npmbuildbot[bot]@users.noreply.github.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Preview/TXT.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Preview/TXT.php b/lib/private/Preview/TXT.php
index 06f60457aff..3090446ac4d 100644
--- a/lib/private/Preview/TXT.php
+++ b/lib/private/Preview/TXT.php
@@ -68,7 +68,7 @@ class TXT extends ProviderV2 {
$lines = preg_split("/\r\n|\n|\r/", $content);
// Define text size of text file preview
- $fontSize = $maxX ? (int) ((2 / 32) * $maxX) : 5; //5px
+ $fontSize = $maxX ? (int) ((1 / 32) * $maxX) : 5; //5px
$lineSize = ceil($fontSize * 1.5);
$image = imagecreate($maxX, $maxY);