summaryrefslogtreecommitdiff
path: root/src/options.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/options.c')
-rw-r--r--src/options.c21
1 files changed, 18 insertions, 3 deletions
diff --git a/src/options.c b/src/options.c
index a77c163..3f405fa 100644
--- a/src/options.c
+++ b/src/options.c
@@ -1,7 +1,7 @@
/* options.c
Copyright (C) 1999-2003 Tom Gilbert.
-Copyright (C) 2010-2020 Daniel Friesel.
+Copyright (C) 2010-2020 Birte Kristina Friesel.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to
@@ -419,13 +419,14 @@ static void feh_parse_option_array(int argc, char **argv, int finalrun)
{"no-xinerama" , 0, 0, OPTION_no_xinerama},
{"draw-tinted" , 0, 0, OPTION_draw_tinted},
{"info" , 1, 0, OPTION_info},
+ {"tap-zones" , 0, 0, OPTION_tap_zones},
{"force-aliasing", 0, 0, OPTION_force_aliasing},
{"no-fehbg" , 0, 0, OPTION_no_fehbg},
{"keep-zoom-vp" , 0, 0, OPTION_keep_zoom_vp},
{"scroll-step" , 1, 0, OPTION_scroll_step},
{"xinerama-index", 1, 0, OPTION_xinerama_index},
{"insecure" , 0, 0, OPTION_insecure},
- {"no-recursive" , 0, 0, OPTION_recursive},
+ {"no-recursive" , 0, 0, OPTION_no_recursive},
{"cache-size" , 1, 0, OPTION_cache_size},
{"on-last-slide" , 1, 0, OPTION_on_last_slide},
{"conversion-timeout" , 1, 0, OPTION_conversion_timeout},
@@ -537,6 +538,8 @@ static void feh_parse_option_array(int argc, char **argv, int finalrun)
case OPTION_sort:
if (!strcasecmp(optarg, "name"))
opt.sort = SORT_NAME;
+ else if (!strcasecmp(optarg, "none"))
+ opt.sort = SORT_NONE;
else if (!strcasecmp(optarg, "filename"))
opt.sort = SORT_FILENAME;
else if (!strcasecmp(optarg, "dirname"))
@@ -758,7 +761,12 @@ static void feh_parse_option_array(int argc, char **argv, int finalrun)
opt.draw_exif = 1;
break;
case OPTION_auto_rotate:
+#if defined(IMLIB2_VERSION_MAJOR) && defined(IMLIB2_VERSION_MINOR) && defined(IMLIB2_VERSION_MICRO) && (IMLIB2_VERSION_MAJOR > 1 || IMLIB2_VERSION_MINOR > 7 || IMLIB2_VERSION_MICRO >= 5)
+ weprintf("This feh release was built with Imlib2 version %d.%d.%d, which transparently adjusts for image orientation according to EXIF data.", IMLIB2_VERSION_MAJOR, IMLIB2_VERSION_MINOR, IMLIB2_VERSION_MICRO);
+ weprintf("--auto-rotate would rotate an already correctly oriented image, resulting in incorrect orientation. It has been disabled in this build. Rebuild feh with Imlib2 <1.7.5 to enable --auto-rotate.");
+#else
opt.auto_rotate = 1;
+#endif
break;
#endif
case OPTION_no_xinerama:
@@ -776,6 +784,9 @@ static void feh_parse_option_array(int argc, char **argv, int finalrun)
opt.draw_info = 1;
}
break;
+ case OPTION_tap_zones:
+ opt.tap_zones = 1;
+ break;
case OPTION_force_aliasing:
opt.force_aliasing = 1;
break;
@@ -838,7 +849,7 @@ static void feh_parse_option_array(int argc, char **argv, int finalrun)
opt.use_conversion_cache = 0;
break;
case OPTION_window_id:
- opt.x11_windowid = atol(optarg);
+ opt.x11_windowid = strtol(optarg, NULL, 0);
break;
case OPTION_zoom_step:
opt.zoom_rate = atof(optarg);
@@ -971,6 +982,10 @@ static void show_version(void)
"help "
#endif
+#ifdef HAVE_LIBMAGIC
+ "magic "
+#endif
+
#if _FILE_OFFSET_BITS == 64
"stat64 "
#endif