diff options
author | Yaroslav de la Peña Smirnov <yps@yaroslavps.com> | 2021-12-12 15:21:53 +0300 |
---|---|---|
committer | Yaroslav de la Peña Smirnov <yps@yaroslavps.com> | 2021-12-12 15:21:53 +0300 |
commit | 9c45f84e3cf5db8349a487f5ef3ca0c5277dc7aa (patch) | |
tree | 26cfff2d534137249ea81459667d543094ceb240 /dotfiles/.config/vifm/scripts/imgt | |
parent | 9fe1fb4369ca36497d4971386670d38c0229ff1f (diff) | |
download | swayrice-9c45f84e3cf5db8349a487f5ef3ca0c5277dc7aa.tar.gz swayrice-9c45f84e3cf5db8349a487f5ef3ca0c5277dc7aa.zip |
Clean up configs
Remove unneeded junk.
Diffstat (limited to 'dotfiles/.config/vifm/scripts/imgt')
-rwxr-xr-x | dotfiles/.config/vifm/scripts/imgt | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/dotfiles/.config/vifm/scripts/imgt b/dotfiles/.config/vifm/scripts/imgt deleted file mode 100755 index 5d76d5d..0000000 --- a/dotfiles/.config/vifm/scripts/imgt +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/bash -# -# Based on script by z3bra -- 2014-01-21 - -W3MIMGDISPLAY="/usr/lib/w3m/w3mimgdisplay" -FONTH=16 # Size of one terminal row -FONTW=9 # Size of one terminal column - -X=$1 -Y=$2 -COLUMNS=$3 -LINES=$4 -FILENAME=$5 - -read width height <<< `echo "5;$FILENAME" | $W3MIMGDISPLAY` -if [ -z "$width" -o -z "$height" ]; then - echo 'Error: Failed to obtain image size.' - exit 1 -fi - -x=$((FONTW * X)) -y=$((FONTH * Y)) - -max_width=$((FONTW * COLUMNS)) -max_height=$((FONTH * LINES)) - -if [ "$width" -gt "$max_width" ]; then - height=$((height * max_width / width)) - width=$max_width -fi -if [ "$height" -gt "$max_height" ]; then - width=$((width * max_height / height)) - height=$max_height -fi - -w3m_command="0;1;$x;$y;$width;$height;;;;;$FILENAME\n4;\n3;" - -echo -e "$w3m_command" | $W3MIMGDISPLAY |