summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Friesel <derf@derf.homelinux.org>2010-02-26 19:55:44 +0100
committerDaniel Friesel <derf@derf.homelinux.org>2010-02-26 19:55:44 +0100
commit26e2d4788639806e8565e45456b51112d2c39956 (patch)
treec1c6bc0862e2a4bddea06497347d78a535c76437
parentebcbef3012dd196066112f219159410b91f45f38 (diff)
Add --index-{name,size,dim} options for finer thumbnail/index text control
-rw-r--r--feh.19
-rw-r--r--src/options.c15
2 files changed, 24 insertions, 0 deletions
diff --git a/feh.1 b/feh.1
index 2613521..3645b36 100644
--- a/feh.1
+++ b/feh.1
@@ -275,6 +275,15 @@ Enable thumbnail caching (in ~/.thumbnails)
.B -~, --thumb-title STRING
Set title for windows opened from thumbnail mode. See also FORMAT SPECIFIERS.
.TP 5
+.B --index-name BOOL
+Show/Don't show filename in thumbnail/index mode.
+.TP 5
+.B --index-size BOOL
+Show/Don't show filesize in thumbnail/index mode.
+.TP 5
+.B --index-dim BOOL
+Show/Don't show image dimensions in thumbnail/index mode.
+.TP 5
.B --bg-tile FILE
.TP 5
.B --bg-center FILE
diff --git a/src/options.c b/src/options.c
index a82dd8a..870388b 100644
--- a/src/options.c
+++ b/src/options.c
@@ -389,6 +389,9 @@ static void feh_parse_option_array(int argc, char **argv)
{"action7", 1, 0, 215},
{"action8", 1, 0, 216},
{"action9", 1, 0, 217},
+ {"index-name", 1, 0, 230},
+ {"index-size", 1, 0, 231},
+ {"index-dim", 1, 0, 232},
{0, 0, 0, 0}
};
int optch = 0, cmdx = 0, i = 0;
@@ -719,6 +722,15 @@ static void feh_parse_option_array(int argc, char **argv)
case 228:
opt.menu_ctrl_mask = 1;
break;
+ case 230:
+ opt.index_show_name = atoi(optarg);
+ break;
+ case 231:
+ opt.index_show_size = atoi(optarg);
+ break;
+ case 232:
+ opt.index_show_dim = atoi(optarg);
+ break;
default:
break;
}
@@ -942,6 +954,9 @@ void show_usage(void)
" Supports format specifiers, see there.\n"
" -I, --fullindex Same as index mode, but below each thumbnail you\n"
" get image name, size and dimensions\n"
+ " --index-name BOOL Show/Don't show filename in index/thumbnail mode\n"
+ " --index-size BOOL Show/Don't show filesize in index/thumbnail mode\n"
+ " --index-dim BOOL Show/Don't show dimensions in index/thumbnail mode\n"
" --bg-tile FILE\n"
" --bg-center FILE\n"
" --bg-scale FILE\n"