aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAraki Ken <arakiken@users.sf.net>2014-10-11 06:46:47 +0000
committerTatsuya Kinoshita <tats@debian.org>2014-12-06 11:47:05 +0000
commitf64d6bb89909bf3c7062ec09ace369c89f24c28e (patch)
tree9eb0272dc451b4ef10c3361b4be7468c6b4b7b17
parentttymode_set() -> ttymode_reset(). (diff)
downloadw3m-f64d6bb89909bf3c7062ec09ace369c89f24c28e.tar.gz
w3m-f64d6bb89909bf3c7062ec09ace369c89f24c28e.zip
If SCREEN_VARIANT=sixel on GNU screen, exec img2sixel without -P option.
Diffstat (limited to '')
-rw-r--r--terms.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/terms.c b/terms.c
index 1c90b58..1545157 100644
--- a/terms.c
+++ b/terms.c
@@ -625,7 +625,8 @@ put_image_sixel(char *url, int x, int y, int w, int h, int sx, int sy, int sw, i
sx*pixel_per_char_i, sy*pixel_per_line_i);
argv[8] = clip;
argv[9] = url;
- if (getenv("TERM") && strcmp(getenv("TERM"), "screen") == 0) {
+ if (getenv("TERM") && strcmp(getenv("TERM"), "screen") == 0 &&
+ (!getenv("SCREEN_VARIANT") || strcmp(getenv("SCREEN_VARIANT"), "sixel") != 0)) {
argv[10] = "-P";
argv[11] = NULL;
}