summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lepus.uberspace.de>2014-02-17 01:19:13 +0100
committerhut <hut@lepus.uberspace.de>2014-02-17 01:19:34 +0100
commit01bf29b307e39d6a7141c93f94715da9314d75e5 (patch)
tree4c4a1eb70d5bf518030c58aa16415a8002e7bc3f
parentc32ca19711501ae299f081cf07ac8eddb46dfbf5 (diff)
downloadranger-01bf29b307e39d6a7141c93f94715da9314d75e5.tar.gz
ext.img_display: fix misplacement of image in previous commit
Thanks to majutsushi, see https://github.com/hut/ranger/issues/109
-rw-r--r--ranger/ext/img_display.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/ranger/ext/img_display.py b/ranger/ext/img_display.py
index 77f8acaa..d470fb24 100644
--- a/ranger/ext/img_display.py
+++ b/ranger/ext/img_display.py
@@ -125,5 +125,8 @@ def _get_font_dimensions():
         output, _ = process.communicate()
         output = output.split()
         xpixels, ypixels = int(output[0]), int(output[1])
+        # adjust for misplacement
+        xpixels += 2
+        ypixels += 2
 
     return (xpixels // cols), (ypixels // rows)