summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorache <ache@ache.one>2017-03-13 23:11:25 +0100
committerache <ache@ache.one>2017-03-13 23:11:25 +0100
commitbcd141a5ba3529f4d3f1118ab090daff3b40dc53 (patch)
treee54afafce0e71311686e8d9788ef62722aebef0f
parentActive video preview (diff)
Better preview for image -like file
-rwxr-xr-xscope.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/scope.sh b/scope.sh
index da7168e..c4cf37d 100755
--- a/scope.sh
+++ b/scope.sh
@@ -55,6 +55,10 @@ if [ "$preview_images" = "True" ]; then
# Image previews for image files. w3mimgdisplay will be called for all
# image files (unless overriden as above), but might fail for
# unsupported types.
+ application/pdf)
+ pdftoppm -f 1 -singlefile -jpeg "$path" .thbn && mv .thbn.jpg "$cached" && exit 6 || exit 1;;
+ image/svg+xml)
+ rsvg-convert "$path" -d 1 -p 2 > "$cached" && exit 6 ||exit 1;;
image/*)
exit 7;;
# Image preview for video, disabled by default.: