From d1f218caad102190c6075098c306d0dac4de83ae Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Tue, 14 Aug 2012 10:47:31 +0200 Subject: imlib.c: When opening via URL, always use URL as filename --- ChangeLog | 2 ++ src/imlib.c | 9 +-------- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/ChangeLog b/ChangeLog index 9cc7838..571e5e8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -10,6 +10,8 @@ git HEAD ** %o x,y image offset relative to top-left window corner ** %r image rotation ** %z image zoom + * Always use file URL as filename when opening http files. + (consequence: lossless rotate no longer works for such files) Sun, 25 Mar 2012 13:13:26 +0200 Daniel Friesel diff --git a/src/imlib.c b/src/imlib.c index e7dcaeb..af7acdd 100644 --- a/src/imlib.c +++ b/src/imlib.c @@ -171,14 +171,7 @@ int feh_load_image(Imlib_Image * im, feh_file * file) file->ed = exif_get_data(tmpname); #endif } - if ((opt.slideshow) && (opt.reload == 0) && (image_source != SRC_MAGICK)) { - free(file->filename); - file->filename = estrdup(tmpname); - - if (!opt.keep_http) - add_file_to_rm_filelist(tmpname); - } - else if ((image_source == SRC_MAGICK) || !opt.keep_http) + if ((image_source == SRC_MAGICK) || !opt.keep_http) unlink(tmpname); free(tmpname); -- cgit v1.2.3 From 22485fb7f08950379f2fa498bd081c1623ea8bbd Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Tue, 21 Aug 2012 17:13:27 +0200 Subject: reload: accept float values --- ChangeLog | 1 + src/keyevents.c | 2 +- src/options.c | 2 +- src/options.h | 2 +- 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 571e5e8..ec5c493 100644 --- a/ChangeLog +++ b/ChangeLog @@ -12,6 +12,7 @@ git HEAD ** %z image zoom * Always use file URL as filename when opening http files. (consequence: lossless rotate no longer works for such files) + * --reload now accepts rational numbers Sun, 25 Mar 2012 13:13:26 +0200 Daniel Friesel diff --git a/src/keyevents.c b/src/keyevents.c index 343b5d1..18853ed 100644 --- a/src/keyevents.c +++ b/src/keyevents.c @@ -750,7 +750,7 @@ void feh_event_handle_keypress(XEvent * ev) if (opt.reload < SLIDESHOW_RELOAD_MAX) opt.reload++; else if (opt.verbose) - weprintf("Cannot set RELOAD higher than %d seconds.", opt.reload); + weprintf("Cannot set RELOAD higher than %f seconds.", opt.reload); } else if (feh_is_kp(&keys.reload_minus, keysym, state)) { if (opt.reload > 1) diff --git a/src/options.c b/src/options.c index c27e11e..6f11d07 100644 --- a/src/options.c +++ b/src/options.c @@ -590,7 +590,7 @@ static void feh_parse_option_array(int argc, char **argv, int finalrun) } break; case 'R': - opt.reload = atoi(optarg); + opt.reload = atof(optarg); break; case 'a': opt.alpha = 1; diff --git a/src/options.h b/src/options.h index cef4215..a763642 100644 --- a/src/options.h +++ b/src/options.h @@ -97,7 +97,7 @@ struct __fehoptions { int limit_w; int limit_h; unsigned int thumb_redraw; - int reload; + double reload; int sort; int debug; int geom_flags; -- cgit v1.2.3 From dfe65efcc0a347f8ae5e710039331b5504e78880 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Mon, 27 Aug 2012 20:58:06 +0200 Subject: fix --filelist trying to load .txt and similar with magick. (closes #96) --- ChangeLog | 1 + src/filelist.c | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/ChangeLog b/ChangeLog index ec5c493..76f5cd9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -13,6 +13,7 @@ git HEAD * Always use file URL as filename when opening http files. (consequence: lossless rotate no longer works for such files) * --reload now accepts rational numbers + * Fix --filelist trying to load .txt files with imagemagick Sun, 25 Mar 2012 13:13:26 +0200 Daniel Friesel diff --git a/src/filelist.c b/src/filelist.c index 34df6cf..920a5ef 100644 --- a/src/filelist.c +++ b/src/filelist.c @@ -456,6 +456,7 @@ gib_list *feh_read_filelist(char *filename) char s[1024], s1[1024]; Imlib_Image tmp_im; struct stat st; + signed short tmp_magick_timeout; if (!filename) return(NULL); @@ -463,6 +464,8 @@ gib_list *feh_read_filelist(char *filename) /* * feh_load_image will fail horribly if filename is not seekable */ + tmp_magick_timeout = opt.magick_timeout; + opt.magick_timeout = -1; if (!stat(filename, &st) && S_ISREG(st.st_mode) && feh_load_image_char(&tmp_im, filename)) { weprintf("Filelist file %s is an image, refusing to use it.\n" @@ -470,6 +473,7 @@ gib_list *feh_read_filelist(char *filename) opt.filelistfile = NULL; return NULL; } + opt.magick_timeout = tmp_magick_timeout; errno = 0; if ((fp = fopen(filename, "r")) == NULL) { -- cgit v1.2.3 From 9ed501cda3934e118af46af78bc737e69bb41568 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Tue, 28 Aug 2012 10:31:21 +0200 Subject: separate mail for feh (derf+feh@) --- man/feh.pre | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/man/feh.pre b/man/feh.pre index a50a66a..4d673f4 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1527,7 +1527,7 @@ window slightly too large. .Ss REPORTING BUGS . If you find a bug, please report it to -.Aq derf@finalrewind.org +.Aq derf+feh@finalrewind.org or via .Aq http://github.com/derf/feh/issues . You are also welcome to direct any feh-related comments/questions/... to #feh -- cgit v1.2.3 From d665f6aeb68def39f123ef4b2f0df5e101fb4265 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Tue, 28 Aug 2012 11:37:09 +0200 Subject: Do not enable imagemagick by default --- ChangeLog | 3 +++ man/feh.pre | 14 ++++---------- src/options.c | 2 +- 3 files changed, 8 insertions(+), 11 deletions(-) diff --git a/ChangeLog b/ChangeLog index 76f5cd9..8f758fc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -14,6 +14,9 @@ git HEAD (consequence: lossless rotate no longer works for such files) * --reload now accepts rational numbers * Fix --filelist trying to load .txt files with imagemagick + * imagemagick support is now disabled by default, to make feh behaviour + less confusing. Set --magick-timeout to a non-negative value to enable + it (--magick-timeout 5 for feh-2.5 behaviour) Sun, 25 Mar 2012 13:13:26 +0200 Daniel Friesel diff --git a/man/feh.pre b/man/feh.pre index 4d673f4..e047286 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -118,18 +118,12 @@ can open any format supported by Imlib2, most notably jpeg and png. If the convert binary .Pq supplied by ImageMagick is available, it also has limited support for many other filetypes, such as -svg, xcf and otf. +svg, xcf and otf. Use +.Cm --magick-timeout Ar num +with a non-negative value to enable it. . For animated images, only the first frame is shown. . -.Pp -. -If you don't like the results produced by convert, disable it with -.Qq --magick-timeout -1 . -Also, note that -.Nm -will only try to convert a file for up to five seconds by default. -. . .Sh OPTIONS . @@ -401,7 +395,7 @@ Stop trying to convert unloadable files after seconds. A negative value disables covert / magick support altogether, a value of zero causes .Nm -to try indefinitely. Default timeout is 5 seconds. +to try indefinitely. By default, magick support is disabled. . .It Cm -M , --menu-font Ar font . diff --git a/src/options.c b/src/options.c index 6f11d07..09ae5cc 100644 --- a/src/options.c +++ b/src/options.c @@ -53,7 +53,7 @@ void init_parse_options(int argc, char **argv) opt.display = 1; opt.aspect = 1; opt.slideshow_delay = 0.0; - opt.magick_timeout = 5; + opt.magick_timeout = -1; opt.thumb_w = 60; opt.thumb_h = 60; opt.thumb_redraw = 10; -- cgit v1.2.3 From 25d2a1c0e9c76fa9c37a697147cba2f944ffbb62 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Tue, 28 Aug 2012 11:48:52 +0200 Subject: release v2.6 --- ChangeLog | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 8f758fc..10d855c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,6 @@ -git HEAD +Tue, 28 Aug 2012 11:46:19 +0200 Daniel Friesel +* Release v2.6 * Dennis Real: EXIF mode fixes, support for more camera models * feh(1): Document behaviour for duplicate key bindings @@ -12,7 +13,7 @@ git HEAD ** %z image zoom * Always use file URL as filename when opening http files. (consequence: lossless rotate no longer works for such files) - * --reload now accepts rational numbers + * --reload now accepts non-decimal values * Fix --filelist trying to load .txt files with imagemagick * imagemagick support is now disabled by default, to make feh behaviour less confusing. Set --magick-timeout to a non-negative value to enable @@ -21,7 +22,6 @@ git HEAD Sun, 25 Mar 2012 13:13:26 +0200 Daniel Friesel * Release v2.5 - * Add R, * and / bindings for , and * Try to convert unloadable files with imagemagick for up to 5 seconds * Add --magick-timeout option to set imagemagick conversion timeout or -- cgit v1.2.3