From 75a6925bd1c65d4353e636e353ea546c9e6d49f7 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Thu, 7 Sep 2017 20:19:55 +0200 Subject: Add terminal key input to manpage --- man/feh.pre | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 4a8b0f8..fb5e28f 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -45,7 +45,8 @@ displays all files in the current directory. . .Nm supports filelists, various image sorting modes, image captions, HTTP and more. -Configurable keyboard and mouse shortcuts are used to control it. +It can be controlled by configurable keyboard and mouse shortcuts, terminal +input and signals. . .Pp . @@ -1210,8 +1211,16 @@ do not. . .Sh KEYS . -In an image window, the following keys may be used -.Pq The strings in Bo square brackets Bc are the config action names : +The following actions and default key bindings can be used in an image window. +.Pq The strings in Bo square brackets Bc are the config action names . +. +If +.Nm +is running inside a terminal and its standard input is not used for images or +filelists, key input from the terminal is also accepted. However, terminal +input support is currently limited to most alphanumeric characters +.Pq 0-9 a-z A-Z and some more , +return and backspace. . .Bl -tag -width indent . -- cgit v1.2.3 From 7eb9d73e908d3c10c06521bb211dc571cb3a8e35 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sat, 16 Sep 2017 20:36:52 +0200 Subject: Add toggle_fixed_geometry ("g") keybinding to enable/disable window auto-resize Closes #326 --- man/feh.pre | 4 ++++ src/keyevents.c | 12 ++++++++++++ src/options.h | 1 + 3 files changed, 17 insertions(+) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index fb5e28f..ac9a81a 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1258,6 +1258,10 @@ Toggle EXIF tag display Save the current filelist as .Qq feh_PID_ID_filelist . +.It g Bq toggle_fixed_geometry +. +Enable/Disable automatic window resize when changing images. +. .It h Bq toggle_pause . Pause/Continue the slideshow. When it is paused, it will not automatically diff --git a/src/keyevents.c b/src/keyevents.c index 14f1a14..d478a5a 100644 --- a/src/keyevents.c +++ b/src/keyevents.c @@ -196,6 +196,7 @@ void init_keyevents(void) { feh_set_kb(&keys.reload_minus, 0, XK_minus, 0, 0, 0, 0); feh_set_kb(&keys.reload_plus, 0, XK_plus, 0, 0, 0, 0); feh_set_kb(&keys.toggle_keep_vp, 0, XK_k, 0, 0, 0, 0); + feh_set_kb(&keys.toggle_fixed_geometry, 0, XK_g, 0, 0, 0, 0); home = getenv("HOME"); confhome = getenv("XDG_CONFIG_HOME"); @@ -504,6 +505,8 @@ fehkey *feh_str_to_kb(char *action) return &keys.reload_plus; else if (!strcmp(action, "toggle_keep_vp")) return &keys.toggle_keep_vp; + else if (!strcmp(action, "toggle_fixed_geometry")) + return &keys.toggle_fixed_geometry; return NULL; } @@ -871,5 +874,14 @@ void feh_event_handle_generic(winwidget winwid, unsigned int state, KeySym keysy else if (feh_is_kp(&keys.toggle_keep_vp, state, keysym, button)) { opt.keep_zoom_vp = !opt.keep_zoom_vp; } + else if (feh_is_kp(&keys.toggle_fixed_geometry, state, keysym, button)) { + if (opt.geom_flags & ((WidthValue | HeightValue))) { + opt.geom_flags &= ~(WidthValue | HeightValue); + } else { + opt.geom_flags |= (WidthValue | HeightValue); + opt.geom_w = winwid->w; + opt.geom_h = winwid->h; + } + } return; } diff --git a/src/options.h b/src/options.h index 5a5ce84..ef7f471 100644 --- a/src/options.h +++ b/src/options.h @@ -208,6 +208,7 @@ struct __fehkb { struct __fehkey reload; struct __fehkey blur; struct __fehkey rotate; + struct __fehkey toggle_fixed_geometry; }; void init_parse_options(int argc, char **argv); -- cgit v1.2.3 From 8af3ee91e39a885ccee3d988ef944634f489ef14 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Thu, 28 Dec 2017 17:29:32 +0100 Subject: Document --cache-size in feh(1) --- man/feh.pre | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index ac9a81a..c2a4cd1 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -205,6 +205,16 @@ Zoom pictures to screen size in fullscreen / fixed geometry mode. . Create borderless windows. . +.It Cm --cache-size Ar size +. +Set Imlib2 in-memory cache to +.Ar size +MiB. A higher cache size can +significantly improve performance especially for small slide shows, however at +the cost of increased memory consumption. +.Ar size +must be between 0 and 2048 MiB and defaults to 4. +. .It Cm -P , --cache-thumbnails . Enable thumbnail caching in -- cgit v1.2.3 From 5965739a0aa6e1f91989a011746c2709cb4e92dc Mon Sep 17 00:00:00 2001 From: Paul O'Day Date: Tue, 26 Mar 2013 20:52:14 -0700 Subject: Allow any XColor values as --image-bg argument --- man/feh.pre | 2 +- src/feh.h | 2 -- src/help.raw | 2 +- src/options.c | 9 +-------- src/options.h | 2 +- src/wallpaper.c | 29 ++++++++++++----------------- src/winwidget.c | 26 ++++++++++++++------------ 7 files changed, 30 insertions(+), 42 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index c2a4cd1..90e6b20 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -379,7 +379,7 @@ Hide the pointer .It Cm -B , --image-bg Ar style . Use style as background for transparent image parts and the like. -Accepted values: checks, white, black. +Accepted values: default, checks, or a XColor (eg. #428bdd). . The default for windowed mode is checks, while fullscreen defaults to black. . diff --git a/src/feh.h b/src/feh.h index a4a0a7b..3f0ce0c 100644 --- a/src/feh.h +++ b/src/feh.h @@ -107,8 +107,6 @@ enum slide_change { SLIDE_NEXT, SLIDE_PREV, SLIDE_RAND, SLIDE_FIRST, SLIDE_LAST, SLIDE_JUMP_PREV_DIR }; -enum image_bg { IMAGE_BG_CHECKS = 1, IMAGE_BG_BLACK, IMAGE_BG_WHITE }; - #define INPLACE_EDIT_FLIP -1 #define INPLACE_EDIT_MIRROR -2 diff --git a/src/help.raw b/src/help.raw index 37e0e71..8b244c1 100644 --- a/src/help.raw +++ b/src/help.raw @@ -84,7 +84,7 @@ OPTIONS can be used multiple times to add multiple paths. -M, --menu-font FONT Use FONT for the font in menus. -B, --image-bg STYLE Set background for transparent images and the like. - Accepted values: white, black, default + Accepted values: default, checks, or a XColor (eg. #428bdd) -N, --no-menus Don't load or show any menus. --no-xinerama Disable Xinerama support --no-screen-clip Do not limit window size to screen size diff --git a/src/options.c b/src/options.c index c874832..03f5ae3 100644 --- a/src/options.c +++ b/src/options.c @@ -449,14 +449,7 @@ static void feh_parse_option_array(int argc, char **argv, int finalrun) opt.actions[0] = estrdup(optarg); break; case 'B': - if (!strcmp(optarg, "checks")) - opt.image_bg = IMAGE_BG_CHECKS; - else if (!strcmp(optarg, "white")) - opt.image_bg = IMAGE_BG_WHITE; - else if (!strcmp(optarg, "black")) - opt.image_bg = IMAGE_BG_BLACK; - else - weprintf("Unknown argument to --image-bg: %s", optarg); + opt.image_bg = estrdup(optarg); break; case 'C': D(("adding fontpath %s\n", optarg)); diff --git a/src/options.h b/src/options.h index c6959c8..fc9774e 100644 --- a/src/options.h +++ b/src/options.h @@ -71,7 +71,6 @@ struct __fehoptions { unsigned char cycle_once; unsigned char hold_actions[10]; unsigned char text_bg; - unsigned char image_bg; unsigned char no_fehbg; unsigned char keep_zoom_vp; unsigned char insecure_ssl; @@ -79,6 +78,7 @@ struct __fehoptions { char *output_file; char *output_dir; char *bg_file; + char *image_bg; char *font; char *title_font; char *title; diff --git a/src/wallpaper.c b/src/wallpaper.c index c9a3a05..5c50ad8 100644 --- a/src/wallpaper.c +++ b/src/wallpaper.c @@ -305,15 +305,19 @@ void feh_wm_set_bg(char *fil, Imlib_Image im, int centered, int scaled, D(("Falling back to XSetRootWindowPixmap\n")); + XColor color; + Colormap cmap = DefaultColormap(disp, DefaultScreen(disp)); + if (opt.image_bg) + XAllocNamedColor(disp, cmap, (char*) opt.image_bg, &color, &color); + else + XAllocNamedColor(disp, cmap, "black", &color, &color); + if (scaled) { pmap_d1 = XCreatePixmap(disp, root, scr->width, scr->height, depth); #ifdef HAVE_LIBXINERAMA if (opt.xinerama_index >= 0) { - if (opt.image_bg == IMAGE_BG_WHITE) - gcval.foreground = WhitePixel(disp, DefaultScreen(disp)); - else - gcval.foreground = BlackPixel(disp, DefaultScreen(disp)); + gcval.foreground = color.pixel; gc = XCreateGC(disp, root, GCForeground, &gcval); XFillRectangle(disp, pmap_d1, gc, 0, 0, scr->width, scr->height); XFreeGC(disp, gc); @@ -337,10 +341,7 @@ void feh_wm_set_bg(char *fil, Imlib_Image im, int centered, int scaled, D(("centering\n")); pmap_d1 = XCreatePixmap(disp, root, scr->width, scr->height, depth); - if (opt.image_bg == IMAGE_BG_WHITE) - gcval.foreground = WhitePixel(disp, DefaultScreen(disp)); - else - gcval.foreground = BlackPixel(disp, DefaultScreen(disp)); + gcval.foreground = color.pixel; gc = XCreateGC(disp, root, GCForeground, &gcval); XFillRectangle(disp, pmap_d1, gc, 0, 0, scr->width, scr->height); @@ -367,10 +368,7 @@ void feh_wm_set_bg(char *fil, Imlib_Image im, int centered, int scaled, #ifdef HAVE_LIBXINERAMA if (opt.xinerama_index >= 0) { - if (opt.image_bg == IMAGE_BG_WHITE) - gcval.foreground = WhitePixel(disp, DefaultScreen(disp)); - else - gcval.foreground = BlackPixel(disp, DefaultScreen(disp)); + gcval.foreground = color.pixel; gc = XCreateGC(disp, root, GCForeground, &gcval); XFillRectangle(disp, pmap_d1, gc, 0, 0, scr->width, scr->height); XFreeGC(disp, gc); @@ -393,10 +391,7 @@ void feh_wm_set_bg(char *fil, Imlib_Image im, int centered, int scaled, } else if (filled == 2) { pmap_d1 = XCreatePixmap(disp, root, scr->width, scr->height, depth); - if (opt.image_bg == IMAGE_BG_WHITE) - gcval.foreground = WhitePixel(disp, DefaultScreen(disp)); - else - gcval.foreground = BlackPixel(disp, DefaultScreen(disp)); + gcval.foreground = color.pixel; gc = XCreateGC(disp, root, GCForeground, &gcval); XFillRectangle(disp, pmap_d1, gc, 0, 0, scr->width, scr->height); @@ -472,7 +467,7 @@ void feh_wm_set_bg(char *fil, Imlib_Image im, int centered, int scaled, free(path); } } - + /* create new display, copy pixmap to new display */ disp2 = XOpenDisplay(NULL); if (!disp2) diff --git a/src/winwidget.c b/src/winwidget.c index d636a85..e0796fa 100644 --- a/src/winwidget.c +++ b/src/winwidget.c @@ -391,17 +391,18 @@ void winwidget_setup_pixmaps(winwidget winwid) if (winwid->gc == None) { XGCValues gcval; - if (opt.image_bg == IMAGE_BG_WHITE) { - gcval.foreground = WhitePixel(disp, DefaultScreen(disp)); + if (!opt.image_bg || !strcmp(opt.image_bg, "default")) { + gcval.foreground = BlackPixel(disp, DefaultScreen(disp)); winwid->gc = XCreateGC(disp, winwid->win, GCForeground, &gcval); - } - else if (opt.image_bg == IMAGE_BG_CHECKS) { + } else if (!strcmp(opt.image_bg, "checks")) { gcval.tile = feh_create_checks(); gcval.fill_style = FillTiled; winwid->gc = XCreateGC(disp, winwid->win, GCTile | GCFillStyle, &gcval); - } - else { - gcval.foreground = BlackPixel(disp, DefaultScreen(disp)); + } else { + XColor color; + Colormap cmap = DefaultColormap(disp, DefaultScreen(disp)); + XAllocNamedColor(disp, cmap, (char*) opt.image_bg, &color, &color); + gcval.foreground = color.pixel; winwid->gc = XCreateGC(disp, winwid->win, GCForeground, &gcval); } } @@ -700,14 +701,15 @@ Pixmap feh_create_checks(void) if (!checks) eprintf("Unable to create a teeny weeny imlib image. I detect problems"); - if (opt.image_bg == IMAGE_BG_WHITE) - gib_imlib_image_fill_rectangle(checks, 0, 0, 16, 16, 255, 255, 255, 255); - else if (opt.image_bg == IMAGE_BG_BLACK) - gib_imlib_image_fill_rectangle(checks, 0, 0, 16, 16, 0, 0, 0, 255); - else { + if (!opt.image_bg || !strcmp(opt.image_bg, "default") || !strcmp(opt.image_bg, "checks")) { gib_imlib_image_fill_rectangle(checks, 0, 0, 16, 16, 144, 144, 144, 255); gib_imlib_image_fill_rectangle(checks, 0, 0, 8, 8, 100, 100, 100, 255); gib_imlib_image_fill_rectangle(checks, 8, 8, 8, 8, 100, 100, 100, 255); + } else { + XColor color; + Colormap cmap = DefaultColormap(disp, DefaultScreen(disp)); + XAllocNamedColor(disp, cmap, (char*) opt.image_bg, &color, &color); + gib_imlib_image_fill_rectangle(checks, 0, 0, 16, 16, color.red, color.green, color.blue, 255); } checks_pmap = XCreatePixmap(disp, root, 16, 16, depth); -- cgit v1.2.3 From c4a98974bece64c5ae6e224151e92e807d5ac271 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Mon, 29 Jan 2018 17:31:06 +0100 Subject: feh(1): Note that --magick-timeout will clutter /tmp FWIW: This behaviour was already present before 394517d1c66783c4e1d044f79df9ef1703a6f5db --- man/feh.pre | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index c2a4cd1..67c5d2a 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -450,6 +450,11 @@ of zero causes .Nm to try indefinitely. By default, magick support is disabled. . +Note that feh may clutter +.Pa /tmp +with temporary files created by ImageMagick for each failed conversion attempt. +This is a known bug. +. .It Cm --max-dimension Ar width No x Ar height . Only show images with width <= @@ -1787,6 +1792,14 @@ as it could be. does not take window decorations into account and may therefore make the window slightly too large. . +.Pp +. +When enabled, +.Cm --magick-timeout +may clutter +.Pa /tmp +with temporary files produced by ImageMagick. This happens whenever an image +is not loaded due to the conversion taking longer than the specified timeout. . .Ss REPORTING BUGS . -- cgit v1.2.3 From ad4f102d94e1cc782c95e262fab90aea4fe8cda4 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Tue, 30 Jan 2018 15:16:09 +0100 Subject: Replace outdated /opt/images example path with ~/Pictures --- man/feh.pre | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 67c5d2a..76f64b3 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1670,56 +1670,56 @@ Here are some examples of useful option combinations. See also: . .Bl -tag -width indent . -.It feh /opt/images +.It feh ~/Pictures . -Show all images in /opt/images +Show all images in ~/Pictures . -.It feh -r /opt/images +.It feh -r ~/Pictures . -Recursively show all images found in /opt/images and subdirectories +Recursively show all images found in ~/Pictures and subdirectories . -.It feh -rSfilename /opt/images +.It feh -rSfilename ~/Pictures . Same as above, but sort by filename. By default, feh will show files in the order it finds them on the hard disk, which is usually somewhat random. . -.It feh -t -Sfilename -E 128 -y 128 -W 1024 /opt/images +.It feh -t -Sfilename -E 128 -y 128 -W 1024 ~/Pictures . Show 128x128 pixel thumbnails, limit window width to 1024 pixels. . -.It feh -t -Sfilename -E 128 -y 128 -W 1024 -P -C /usr/share/fonts/truetype/ttf-dejavu/ -e DejaVuSans/8 /opt/images +.It feh -t -Sfilename -E 128 -y 128 -W 1024 -P -C /usr/share/fonts/truetype/ttf-dejavu/ -e DejaVuSans/8 ~/Pictures . Same as above, but enable thumbnail caching in ~/.thumbnails and use a smaller font. . -.It feh -irFarial/14 -O index.jpg /opt/images +.It feh -irFarial/14 -O index.jpg ~/Pictures . -Make an index print of /opt/images and all directories below it, using 14 point +Make an index print of ~/Pictures and all directories below it, using 14 point Arial to write the image info under each thumbnail. Save the image as index.jpg and don't display it, just exit. Note that this even works without a running X server . -.It feh --unloadable -r /opt/images +.It feh --unloadable -r ~/Pictures . -Print all unloadable images in /opt/images, recursively +Print all unloadable images in ~/Pictures, recursively . .It feh -f by_width -S width --reverse --list \&. . Write a list of all images in the directory to by_width, sorted by width .Pq widest images first . -.It feh -w /opt/images/holidays +.It feh -w ~/Pictures/holidays . -Open each image in /opt/images/holidays in its own window +Open each image in ~/Pictures/holidays in its own window . -.It feh -FD5 -Sname /opt/images/presentation +.It feh -FD5 -Sname ~/Pictures/presentation . Show the images in .../presentation, sorted by name, in fullscreen, automatically change to the next image after 5 seconds . -.It feh -rSwidth -A Qo mv %F ~/images/\&%N Qc /opt/images +.It feh -rSwidth -A Qo mv %F ~/images/\&%N Qc ~/Pictures . -View all images in /opt/images and below, sorted by width, move an image to +View all images in ~/Pictures and below, sorted by width, move an image to ~/image/image_name when enter is pressed . .It feh --start-at ./foo.jpg \&. -- cgit v1.2.3 From eed4b7c824592d127b5993da7ce0d8020576241a Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sat, 10 Feb 2018 16:57:24 +0100 Subject: feh(1): Document current theme quoting and parser behaviour --- man/feh.pre | 25 ++++++++++++++++++------- 1 file changed, 18 insertions(+), 7 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 76f64b3..f5d9b9c 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1111,16 +1111,27 @@ is the name of the entry and .Ar options are the options which will be applied when the theme is used. . -Note that the options are not parsed by any shell. Therefore, filename expansion -.Po -.Qq *.jpg -and similar -.Pc -is not supported. Quoting with both single and double quotes works, though. +.Pp +. +Note that the option parser does not behave like a normal shell: filename +expansion and backslash escape sequences are not supported and passed to +feh's option parser as-is. However, quoting of arguments is respected +and can be used for arguments with whitespace. +. +So, the sequence +.Qq --info Qq foo bar +works as intended +.Pq that is, it display the string Qq foo bar , +whereas the option string +.Qq --info foo\e bar +will only display +.Qq foo\e +and complain about the file bar not existing. +Please keep this in mind when writing theme files. . .Pp . -An example entry would be +An example entry is .Qq imagemap -rVq --thumb-width 40 --thumb-height 30 --index-info \&'%n\en\&%wx\&%h\&' . . .Pp -- cgit v1.2.3 From 6452404d310252bad6d09979f2a2e28bb58f2746 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Tue, 27 Feb 2018 17:50:54 +0100 Subject: Update feh(1) --- man/feh.pre | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 6a022dc..ab3f8d6 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -378,10 +378,16 @@ Hide the pointer . .It Cm -B , --image-bg Ar style . -Use style as background for transparent image parts and the like. -Accepted values: default, checks, or a XColor (eg. #428bdd). -. -The default for windowed mode is checks, while fullscreen defaults to black. +Use +.Ar style +as background for transparent image parts and the like. +Accepted values: default, checks, or an XColor +.Pq eg. Qo black Qc or Qo #428bdd Qc . +. +In windowed mode, the default is checks +.Pq a checkered background so transparent image parts are easy to see . +In fullscreen and background setting mode, checks is not accepted and the +default is black. . .It Cm -i , --index . -- cgit v1.2.3 From b251f26261309c933a43c863f81227219a9e8355 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 28 Feb 2018 17:31:34 +0100 Subject: feh(1): Show state of optional switches right next to them --- man/feh.pre | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index ab3f8d6..d332774 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -194,7 +194,7 @@ Extra actions which can be set and triggered using the appropriate number key. . .It Cm --auto-rotate . -.Pq only if compiled with exif=1 +.Pq optional feature, $MAN_EXIF$ in this build Automatically rotate images based on EXIF data. Does not alter the image files. . .It Cm -Z , --auto-zoom @@ -253,7 +253,7 @@ Draw the defined actions and what they do at the top-left of the image. . .It Cm --draw-exif . -.Pq only if compiled with exif=1 +.Pq optional feature, $MAN_EXIF$ in this build display some EXIF information in the bottom left corner, similar to using .Cm --info with exiv2 / exifgrep . @@ -514,8 +514,8 @@ managers. . .It Cm --no-xinerama . -Disable Xinerama support. Only makes sense when you have Xinerama support -compiled in. +.Pq optional feature, $MAN_XINERAMA$ in this build +Disable Xinerama support. . .It Cm -j , --output-dir Ar directory . @@ -698,6 +698,7 @@ output version information and exit. . .It Cm --xinerama-index Ar screen . +.Pq optional feature, $MAN_XINERAMA$ in this build Override .Nm Ns No 's idea of the active Xinerama screen. May be useful in certain circumstances @@ -1282,7 +1283,7 @@ Toggle filename display . .It e Bq toggle_exif . -.Pq only if compiled with exif=1 +.Pq optional feature, $MAN_EXIF$ in this build Toggle EXIF tag display . .It f Bq save_filelist -- cgit v1.2.3 From 4567042b5145b097c962499f26511aa5106f0e60 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 28 Feb 2018 17:53:51 +0100 Subject: Add Makefile flag to disable version sorting on C libraries without strverscmp --- README.md | 1 + config.mk | 10 +++++++++- man/Makefile | 1 + man/feh.pre | 3 ++- src/feh.h | 7 +++++++ src/filelist.c | 29 +++++++++++++++-------------- 6 files changed, 35 insertions(+), 16 deletions(-) (limited to 'man') diff --git a/README.md b/README.md index 328897a..7848158 100644 --- a/README.md +++ b/README.md @@ -83,6 +83,7 @@ Available flags are: | exif | 0 | Builtin EXIF tag display support | | help | 0 | include help text (refers to the manpage otherwise) | | stat64 | 0 | Support CIFS shares from 64bit hosts on 32bit machines | +| verscmp | 1 | Support naturing sorting (`--version-sort`). Requires a GNU-compatible libc exposing `strverscmp` | | xinerama | 1 | Support Xinerama/XRandR multiscreen setups | So, by default **libcurl** and **Xinerama** are enabled, the rest is disabled. diff --git a/config.mk b/config.mk index 8769b1d..226c612 100644 --- a/config.mk +++ b/config.mk @@ -5,9 +5,10 @@ app ?= 0 cam ?= 0 curl ?= 1 debug ?= 0 +exif ?= 0 help ?= 0 +verscmp ?= 1 xinerama ?= 1 -exif ?= 0 # Prefix for all installed files PREFIX ?= /usr/local @@ -63,6 +64,13 @@ ifeq (${stat64},1) CFLAGS += -D_FILE_OFFSET_BITS=64 endif +ifeq (${verscmp},1) + CFLAGS += -DHAVE_VERSCMP + MAN_VERSCMP = enabled +else + MAN_VERSCMP = disabled +endif + ifeq (${xinerama},1) CFLAGS += -DHAVE_LIBXINERAMA LDLIBS += -lXinerama diff --git a/man/Makefile b/man/Makefile index 65f2bc2..9209de1 100644 --- a/man/Makefile +++ b/man/Makefile @@ -12,6 +12,7 @@ all: ${TARGETS} -e 's/\$$MAN_CURL\$$/${MAN_CURL}/' \ -e 's/\$$MAN_DEBUG\$$/${MAN_DEBUG}/' \ -e 's/\$$MAN_EXIF\$$/${MAN_EXIF}/' \ + -e 's/\$$MAN_VERSCMP\$$/${MAN_VERSCMP}/' \ -e 's/\$$MAN_XINERAMA\$$/${MAN_XINERAMA}/' \ < ${@:.1=.pre} > $@ diff --git a/man/feh.pre b/man/feh.pre index d332774..640ae3f 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -24,7 +24,8 @@ $VERSION$ . .Pp . -Compile-time switches: libcurl support $MAN_CURL$, Xinerama support +Compile-time switches: libcurl support $MAN_CURL$, natural sorting support +$MAN_VERSCMP$, Xinerama support $MAN_XINERAMA$, builtin EXIF support $MAN_EXIF$$MAN_DEBUG$ . . diff --git a/src/feh.h b/src/feh.h index 4e7a3ff..3e0cdda 100644 --- a/src/feh.h +++ b/src/feh.h @@ -27,7 +27,14 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #ifndef FEH_H #define FEH_H +/* + * strverscmp(3) is a GNU extension. In most supporting C libraries it + * requires _GNU_SOURCE to be defined. + */ +#ifdef HAVE_VERSCMP #define _GNU_SOURCE +#endif + #include #include #include diff --git a/src/filelist.c b/src/filelist.c index 159491a..453f795 100644 --- a/src/filelist.c +++ b/src/filelist.c @@ -397,20 +397,26 @@ void feh_file_dirname(char *dst, feh_file * f, int maxlen) dst[n] = '\0'; } -int feh_cmp_filename(void *file1, void *file2) +#ifdef HAVE_VERSCMP +inline int strcmp_or_strverscmp(const char *s1, const char *s2) { if (!opt.version_sort) - return(strcmp(FEH_FILE(file1)->filename, FEH_FILE(file2)->filename)); + return(strcmp(s1, s2)); else - return(strverscmp(FEH_FILE(file1)->filename, FEH_FILE(file2)->filename)); + return(strverscmp(s1, s2)); +} +#else +#define strcmp_or_strverscmp strcmp +#endif + +int feh_cmp_filename(void *file1, void *file2) +{ + return(strcmp_or_strverscmp(FEH_FILE(file1)->filename, FEH_FILE(file2)->filename)); } int feh_cmp_name(void *file1, void *file2) { - if (!opt.version_sort) - return(strcmp(FEH_FILE(file1)->name, FEH_FILE(file2)->name)); - else - return(strverscmp(FEH_FILE(file1)->name, FEH_FILE(file2)->name)); + return(strcmp_or_strverscmp(FEH_FILE(file1)->name, FEH_FILE(file2)->name)); } int feh_cmp_dirname(void *file1, void *file2) @@ -419,13 +425,8 @@ int feh_cmp_dirname(void *file1, void *file2) int cmp; feh_file_dirname(dir1, FEH_FILE(file1), PATH_MAX); feh_file_dirname(dir2, FEH_FILE(file2), PATH_MAX); - if (!opt.version_sort) { - if ((cmp = strcmp(dir1, dir2)) != 0) - return(cmp); - } else { - if ((cmp = strverscmp(dir1, dir2)) != 0) - return(cmp); - } + if ((cmp = strcmp_or_strverscmp(dir1, dir2)) != 0) + return(cmp); return(feh_cmp_name(file1, file2)); } -- cgit v1.2.3 From 5a2db8f2ffc4371d2e88a65567d85663e6d16b36 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 28 Feb 2018 17:54:17 +0100 Subject: Document --version-sort in feh(1) --- man/feh.pre | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 640ae3f..5290f79 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -697,6 +697,15 @@ output useful information, progress bars, etc. . output version information and exit. . +.It Cm --version-sort +. +.Pq optional feature, $MAN_VERSCMP$ in this build +Use natural sorting for file and directory names. In this mode, filenames are +sorted as an ordinary human would expect, e.g. +.Qq 2.jpg +comes before +.Qq 10.jpg . +. .It Cm --xinerama-index Ar screen . .Pq optional feature, $MAN_XINERAMA$ in this build @@ -1697,10 +1706,14 @@ Show all images in ~/Pictures . Recursively show all images found in ~/Pictures and subdirectories . -.It feh -rSfilename ~/Pictures +.It feh -rSfilename --version-sort ~/Pictures . -Same as above, but sort by filename. By default, feh will show files in the -order it finds them on the hard disk, which is usually somewhat random. +Same as above, but sort naturally. By default, feh will show files in the +string order of their names, meaning e.g. +.Qq foo 10.jpg +will come before +.Qq foo 2.jpg . +In this case, they are instead ordered as a human would expect. . .It feh -t -Sfilename -E 128 -y 128 -W 1024 ~/Pictures . -- cgit v1.2.3 From c2e0b7239522dc417b87f45cd133fb8f046dedfa Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 28 Feb 2018 19:44:21 +0100 Subject: Respect --geometry in --bg-fill (closes #209) --- man/feh.pre | 10 +++++----- src/wallpaper.c | 27 ++++++++++++++++++++++++++- 2 files changed, 31 insertions(+), 6 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 5290f79..46de5d1 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -919,13 +919,13 @@ instead. . .Pp . -For the -.Cm --bg-center +For +.Cm --bg-center , --bg-fill , and -.Cm --bg-max -options, you can use the +.Cm --bg-max , +you can use .Cm --geometry -option to specify an offset from one side of the screen instead of +to specify an offset from one side of the screen instead of centering the image. Positive values will offset from the left/top side, negative values from the bottom/right. +0 and -0 are both valid and distinct values. diff --git a/src/wallpaper.c b/src/wallpaper.c index 758a81a..2d3d3bc 100644 --- a/src/wallpaper.c +++ b/src/wallpaper.c @@ -160,11 +160,36 @@ static void feh_wm_set_bg_filled(Pixmap pmap, Imlib_Image im, int use_filelist, render_x = ( cut_x ? ((img_w - render_w) >> 1) : 0); render_y = ( !cut_x ? ((img_h - render_h) >> 1) : 0); + if ((opt.geom_flags & XValue) && cut_x) { + if (opt.geom_flags & XNegative) { + render_x = img_w - render_w + opt.geom_x; + } else { + render_x = opt.geom_x; + } + if (render_x < 0) { + render_x = 0; + } else if (render_x + render_w > img_w) { + render_x = img_w - render_w; + } + } + else if ((opt.geom_flags & YValue) && !cut_x) { + if (opt.geom_flags & YNegative) { + render_y = img_h - render_h + opt.geom_y; + } else { + render_y = opt.geom_y; + } + if (render_y < 0) { + render_y = 0; + } else if (render_y + render_h > img_h) { + render_y = img_h - render_h; + } + } + gib_imlib_render_image_part_on_drawable_at_size(pmap, im, render_x, render_y, render_w, render_h, x, y, w, h, - 1, 0, !opt.force_aliasing); + 1, 1, !opt.force_aliasing); if (use_filelist) gib_imlib_free_image_and_decache(im); -- cgit v1.2.3 From 81656da71b514d3519c9930d26e100f12da65a49 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 28 Feb 2018 19:49:56 +0100 Subject: feh(1): Note that --bg-{center,fill} respect --image-bg --- man/feh.pre | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 46de5d1..6c619cd 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -958,7 +958,8 @@ as a background setter for a specific screen. .It Cm --bg-center . Center the file on the background. If it is too small, it will be surrounded -by a black border +by a border as specified by +.Cm --image-bg . . .It Cm --bg-fill . @@ -971,7 +972,9 @@ horizontal or a vertical part of the image will be cut off . Like .Cm --bg-fill , -but scale the image to the maximum size that fits the screen with black borders on one side. +but scale the image to the maximum size that fits the screen with borders on one side. +The border color can be set using +.Cm --image-bg . . .It Cm --bg-scale . -- cgit v1.2.3 From d03fc61a268048e1bcef04fb00883c6cd339027b Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 28 Feb 2018 20:06:33 +0100 Subject: Add toggle_auto_zoom key binding, defaulting to Z Closes #218 --- man/feh.pre | 4 ++++ src/keyevents.c | 5 +++++ src/options.h | 1 + 3 files changed, 10 insertions(+) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 6c619cd..d90c880 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1376,6 +1376,10 @@ Close current window . Jump to a random position in the current filelist . +.It Z Bq toggle_auto_zoom +. +Toggle auto-zoom. +. .It \&[, \&] Bq prev_dir, next_dir . Jump to the first image of the previous or next sequence of images sharing diff --git a/src/keyevents.c b/src/keyevents.c index f082a78..793767b 100644 --- a/src/keyevents.c +++ b/src/keyevents.c @@ -185,6 +185,7 @@ void init_keyevents(void) { feh_set_kb("render" , 0, XK_KP_Begin , 0, XK_R , 0, 0); feh_set_kb("toggle_actions" , 0, XK_a, 0, 0, 0, 0); feh_set_kb("toggle_aliasing" , 0, XK_A, 0, 0, 0, 0); + feh_set_kb("toggle_auto_zoom" , 0, XK_Z, 0, 0, 0, 0); #ifdef HAVE_LIBEXIF feh_set_kb("toggle_exif" , 0, XK_e, 0, 0, 0, 0); #endif @@ -637,6 +638,10 @@ void feh_event_handle_generic(winwidget winwid, unsigned int state, KeySym keysy winwid->force_aliasing = !winwid->force_aliasing; winwidget_render_image(winwid, 0, 0); } + else if (feh_is_kp(EVENT_toggle_auto_zoom, state, keysym, button)) { + opt.zoom_mode = (opt.zoom_mode == 0 ? ZOOM_MODE_MAX : 0); + winwidget_rerender_all(1); + } else if (feh_is_kp(EVENT_toggle_filenames, state, keysym, button)) { opt.draw_filename = !opt.draw_filename; winwidget_rerender_all(0); diff --git a/src/options.h b/src/options.h index c6b4e0e..d4de3c5 100644 --- a/src/options.h +++ b/src/options.h @@ -189,6 +189,7 @@ enum key_action { EVENT_render, EVENT_toggle_actions, EVENT_toggle_aliasing, + EVENT_toggle_auto_zoom, #ifdef HAVE_LIBEXIF EVENT_toggle_exif, #endif -- cgit v1.2.3 From b7867141037ce8c64df54bddb8f636b2545425a0 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 28 Feb 2018 21:05:15 +0100 Subject: Explicitly document index and thumbnail mode options Closes #272 --- man/feh.pre | 45 +++++++++++++++++++++++++-------------------- 1 file changed, 25 insertions(+), 20 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index d90c880..7b1e791 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -832,31 +832,17 @@ Set thumbnail height. . Set thumbnail width. . -.It Cm -J , --thumb-redraw Ar n -. -Only relevant for -.Cm --thumbnails : -Redraw thumbnail window every -.Ar n -images. In -.Nm -<= 1.5, the thumbnail image used to be redrawn after every computed thumbnail -.Pq so, it updated immediately . -However, since the redrawing takes quite long -.Pq especially for thumbnail mode on a large filelist , -this turned out to be a major performance penalty. -As a workaround, the thumbnail image is redrawn every 10th image now by -default. Set -.Ar n No = 1 -to get the old behaviour, -.Ar n No = 0 -will only redraw once all thumbnails are loaded. -. .El . . .Sh INDEX AND THUMBNAIL MODE OPTIONS . +In addition to +.Sx MONTAGE MODE OPTIONS +.Cm --alpha , --bg , --limit-height , --limit-width , --output , --output-only , +.Cm --thumb-height , --thumb-width , +the following options can be used. +. .Bl -tag -width indent . .It Cm --index-info Ar format @@ -887,6 +873,25 @@ to get a progress bar. . Set font to print a title on the index, if no font is specified, no title will be printed. +. +.It Cm -J , --thumb-redraw Ar n +. +Redraw thumbnail window every +.Ar n +images. In +.Nm +<= 1.5, the thumbnail image used to be redrawn after every computed thumbnail +.Pq so, it updated immediately . +However, since the redrawing takes quite long +.Pq especially for thumbnail mode on a large filelist , +this turned out to be a major performance penalty. +As a workaround, the thumbnail image is redrawn every 10th image now by +default. Set +.Ar n No = 1 +to get the old behaviour, +.Ar n No = 0 +will only redraw once all thumbnails are loaded. +. .El . . -- cgit v1.2.3 From a6a325af3b192035694deb38907312de50ef6965 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Mon, 5 Mar 2018 21:55:38 +0100 Subject: feh(1): Fix misleading argument specification for --geometry Closes #386 --- man/feh.pre | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 7b1e791..eb31f37 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -360,7 +360,7 @@ When combined with this option only affects images opened from the thumbnail overview. The thumbnail list itself will still be windowed. . -.It Cm -g , --geometry Oo Ar width No x Ar height Oc Op + Ar x No + Ar y +.It Cm -g , --geometry Ar width Cm x Ar height No | Cm + Ar x Cm + Ar y | Ar width Cm x Ar height Cm + Ar x Cm + Ar y . Limit (and don't change) the window size. Takes an X-style geometry .Ar string -- cgit v1.2.3 From 1d0ba2fc45e06c05e191d123278da019f798d504 Mon Sep 17 00:00:00 2001 From: orbea Date: Mon, 2 Apr 2018 07:54:41 -0700 Subject: feh.1: Fix mandoc warnings This fixes many warnings shown by mandoc lint feature and should also respect the 80 col limit. man -Tlint feh WARNING: new sentence, new line new sentence, new line (mdoc) A new sentence starts in the middle of a text line. Start it on a new input line to help formatters produce correct spacing. man: /usr/man/man1/feh.1.gz:35:32: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:78:33: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:90:50: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:95:53: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:97:23: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:108:17: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:112:36: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:115:24: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:122:20: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:129:21: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:130:9: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:135:19: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:146:64: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:148:43: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:149:58: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:167:2: WARNING: skipping empty macro: No man: /usr/man/man1/feh.1.gz:175:21: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:177:30: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:178:19: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:186:42: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:189:15: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:199:49: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:213:6: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:227:47: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:231:19: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:242:11: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:274:66: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:285:19: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:297:9: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:311:19: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:340:21: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:351:14: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:360:69: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:365:44: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:372:35: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:395:21: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:396:16: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:397:31: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:406:65: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:407:53: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:430:11: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:440:24: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:442:11: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:447:24: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:455:10: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:458:22: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:491:23: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:492:44: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:493:42: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:498:26: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:511:59: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:512:55: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:530:18: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:531:46: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:532:24: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:533:41: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:538:50: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:545:13: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:562:11: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:569:41: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:576:26: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:584:23: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:607:49: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:616:61: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:617:76: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:623:61: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:635:23: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:638:27: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:640:37: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:650:17: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:666:37: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:677:42: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:682:20: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:683:8: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:688:24: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:703:51: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:714:37: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:728:23: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:729:44: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:738:61: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:775:34: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:778:42: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:787:36: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:822:19: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:823:22: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:852:46: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:868:26: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:881:10: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:889:10: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:902:43: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:920:65: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:934:23: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:954:69: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:965:37: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:973:65: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:987:17: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1027:29: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1056:17: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1143:28: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1164:38: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1171:49: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1240:54: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1271:58: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1289:22: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1291:57: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1292:59: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1293:53: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1318:32: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1329:35: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1335:13: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1341:18: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1349:22: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1358:24: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1391:44: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1398:25: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1399:8: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1405:67: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1408:23: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1569:22: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1680:21: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1681:70: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1683:22: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1708:55: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1723:36: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1742:54: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1743:45: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1771:67: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1816:35: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1822:14: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1845:47: WARNING: new sentence, new line man: /usr/man/man1/feh.1.gz:1902:56: WARNING: new sentence, new line --- man/feh.pre | 478 +++++++++++++++++++++++++++++++++++------------------------- 1 file changed, 279 insertions(+), 199 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index eb31f37..3119e48 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -32,9 +32,9 @@ $MAN_XINERAMA$, builtin EXIF support $MAN_EXIF$$MAN_DEBUG$ .Sh DESCRIPTION . .Nm -is a mode-based image viewer. It is especially aimed at command line users who -need a fast image viewer without huge GUI dependencies, though it can also be -started by +is a mode-based image viewer. +It is especially aimed at command line users who need a fast image viewer +without huge GUI dependencies, though it can also be started by .Pq graphical file managers to view an image. By default @@ -75,8 +75,9 @@ options. . .Pp . -Slideshow mode is the default. It opens a window and displays the first -image in it; the slideshow position can be advanced +Slideshow mode is the default. +It opens a window and displays the first image in it; +the slideshow position can be advanced .Pq or otherwise changed using keyboard and mouse shortcuts. In slideshow mode, images can be deleted either from the filelist or from the @@ -87,14 +88,17 @@ An image can also be read from stdin via . .Pp . -Montage mode forms a montage from the filelist. The resulting image can be -viewed or saved, and its size can be limited by height, width or both. +Montage mode forms a montage from the filelist. +The resulting image can be viewed or saved, +and its size can be limited by height, width or both. . .Pp . -Index mode forms an index print from the filelist. Image thumbnails are shown -along with the filename, filesize and pixel size, printed using a truetype -font of your choice. The resulting image can be viewed or saved, and its size +Index mode forms an index print from the filelist. +Image thumbnails are shown along with the filename, +filesize and pixel size, printed using a truetype +font of your choice. +The resulting image can be viewed or saved, and its size can be limited by height, width or both. . .Pp @@ -105,34 +109,40 @@ the selected image in a new window. .Pp . Multiwindow mode shows images in multiple windows, instead of as a slideshow -in one window. Don't use with a large filelist ;) +in one window. +Don't use with a large filelist ;) . .Pp . -List mode doesn't display images. Instead, it outputs an +List mode doesn't display images. +Instead, it outputs an .Cm ls Ns No - Ns style listing of the files in the filelist, including image info such as size, number -of pixels, type, etc. There is also a Customlist mode which prints image info +of pixels, type, etc. +There is also a Customlist mode which prints image info in a custom format specified by a printf-like format string. . .Pp . .Nm can also list either all the loadable files in a filelist or all the -unloadable files. This is useful for preening a directory. +unloadable files. +This is useful for preening a directory. . . .Sh SUPPORTED FORMATS . .Nm can open any format supported by Imlib2, most notably jpeg, png, -pnm, tiff, and bmp. The gif format is also supported, but only for static -images. In case of animations, only the first frame will be shown. +pnm, tiff, and bmp. +The gif format is also supported, but only for static images. +In case of animations, only the first frame will be shown. . 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. Use +svg, xcf and otf. +Use .Cm --magick-timeout Ar num with a non-negative value to enable it. . @@ -143,11 +153,13 @@ with a non-negative value to enable it. . .It Cm -A , --action Oo Ar flag Oc Ns Oo [ Ar title ] Oc Ns Ar action . -Specify a shell command as an action to perform on the image. In slideshow or -multiwindow mode, the action will be run when the action_0 key is pressed, in -list mode, it will be run for each file. In loadable/unloadable mode, it will -be run for each loadable/unloadable file, respectively. In thumbnail mode, -clicking on an image will cause the action to run instead of opening the image. +Specify a shell command as an action to perform on the image. +In slideshow or multiwindow mode, the action will be run when +the action_0 key is pressed, in list mode, it will be run for each file. +In loadable/unloadable mode, it will be run for each loadable/unloadable +file, respectively. +In thumbnail mode, clicking on an image will cause the action to run instead +of opening the image. . .Pp . @@ -172,10 +184,12 @@ will display .Ar title instead of .Ar action -in the action list. Note that +in the action list. +Note that .Ar title -must not start with a space. If it does, the action is handled as if it did -not have a title. This special case exists for backwards compatibility reasons +must not start with a space. +If it does, the action is handled as if it did not have a title. +This special case exists for backwards compatibility reasons and makes sure that actions like .Qq \&[ -L %F \&] && foo still work. @@ -183,10 +197,11 @@ still work. . .Pp . -The action will be executed by /bin/sh. Use format specifiers to refer to -image info, see +The action will be executed by /bin/sh. +Use format specifiers to refer to image info, see .Sx FORMAT SPECIFIERS -for details. Example usage: +for details. +Example usage: .Qq feh -A Qo mv ~/images/%N Qc * . . .It Cm --action1 No .. Cm --action9 Oo Ar flag Oc Ns Oo [ Ar title ] Oc Ns Ar action @@ -196,7 +211,8 @@ Extra actions which can be set and triggered using the appropriate number key. .It Cm --auto-rotate . .Pq optional feature, $MAN_EXIF$ in this build -Automatically rotate images based on EXIF data. Does not alter the image files. +Automatically rotate images based on EXIF data. +Does not alter the image files. . .It Cm -Z , --auto-zoom . @@ -210,9 +226,9 @@ Create borderless windows. . Set Imlib2 in-memory cache to .Ar size -MiB. A higher cache size can -significantly improve performance especially for small slide shows, however at -the cost of increased memory consumption. +MiB. +A higher cache size can significantly improve performance especially for small +slide shows, however at the cost of increased memory consumption. .Ar size must be between 0 and 2048 MiB and defaults to 4. . @@ -224,11 +240,12 @@ Only works with thumbnails <= 256x256 pixels. . .It Cm -K , --caption-path Ar path . -Path to directory containing image captions. This turns on caption viewing, -and if captions are found in +Path to directory containing image captions. +This turns on caption viewing, and if captions are found in .Ar path , which is relative to the directory of each image, they are overlayed on the -displayed image. E.g. with caption path +displayed image. +E.g. with caption path .Qq captions/ , and viewing image .Qq images/foo.jpg , @@ -239,7 +256,8 @@ the caption will be looked for in . Don't display images, print image info according to .Ar format -instead. See +instead. +See .Sx FORMAT SPECIFIERS . . .It Cm --cycle-once @@ -271,7 +289,8 @@ on a semi-transparent background to improve their readability . .It Cm -f , --filelist Ar file . -This option is similar to the playlists used by music software. If +This option is similar to the playlists used by music software. +If .Ar file exists, it will be read for a list of files to load, in the order they appear. The format is a list of image filenames, absolute or relative to the current @@ -282,7 +301,8 @@ directory, one filename per line. If .Ar file doesn't exist, it will be created from the internal filelist at the end of a -viewing session. This is best used to store the results of complex sorts +viewing session. +This is best used to store the results of complex sorts .Pq Cm -Spixels No for example for later viewing. . @@ -294,7 +314,8 @@ will be saved to .Ar file when .Nm -exits. You can add files to filelists by specifying them on the command line +exits. +You can add files to filelists by specifying them on the command line when also specifying the list. . .Pp @@ -308,8 +329,9 @@ will read the filelist from its standard input. . .It Cm -e , --font Ar font . -Set global font. Should be a truetype font, resident in the current directory -or the font directory, and should be defined in the form fontname/points, like +Set global font. +Should be a truetype font, resident in the current directory or the directory, +and should be defined in the form fontname/points, like .Qq myfont/12 . . .It Cm -C , --fontpath Ar path @@ -337,7 +359,8 @@ Note: This option needs to load all images to calculate the dimensions of the .Nm window, so when using it with many files it will take a while before a .Nm -window is visible. Use +window is visible. +Use .Cm --preload to get a progress bar. . @@ -348,7 +371,8 @@ Note that in this mode, large images will always be scaled down to fit the screen, .Cm --zoom Ar zoom only affects smaller images and never scales larger than necessary to fit the -screen size. The only exception is a +screen size. +The only exception is a .Ar zoom of 100, in which case images will always be shown at 100% zoom, no matter their dimensions. @@ -357,20 +381,21 @@ their dimensions. . When combined with .Cm --thumbnails , -this option only affects images opened from the thumbnail overview. The -thumbnail list itself will still be windowed. +this option only affects images opened from the thumbnail overview. +The thumbnail list itself will still be windowed. . .It Cm -g , --geometry Ar width Cm x Ar height No | Cm + Ar x Cm + Ar y | Ar width Cm x Ar height Cm + Ar x Cm + Ar y . -Limit (and don't change) the window size. Takes an X-style geometry +Limit (and don't change) the window size. +Takes an X-style geometry .Ar string like 640x480 with optional +x+y window offset. Note that larger images will be zoomed out to fit, but you can see them at 1:1 by clicking the zoom button. . Also note that this option does not enforce the geometry, changing it by a tiling -WM or manually is still possible. After each resize, the resulting window size -is used as the new size limit. +WM or manually is still possible. +After each resize, the resulting window size is used as the new size limit. . .It Cm -Y , --hide-pointer . @@ -392,9 +417,11 @@ default is black. . .It Cm -i , --index . -Enable Index mode. Index mode is similar to montage mode, and accepts the -same options. It creates an index print of thumbnails, printing the image -name beneath each thumbnail. Index mode enables certain other options, see +Enable Index mode. +Index mode is similar to montage mode, and accepts the same options. +It creates an index print of thumbnails, printing the image name beneath +each thumbnail. +Index mode enables certain other options, see .Sx INDEX AND THUMBNAIL MODE OPTIONS and .Sx MONTAGE MODE OPTIONS . @@ -403,8 +430,9 @@ and . Execute .Ar commandline -and display its output in the bottom left corner of the image. Can be used to -display e.g. image dimensions or EXIF information. Supports +and display its output in the bottom left corner of the image. +Can be used to display e.g. image dimensions or EXIF information. +Supports .Sx FORMAT SPECIFIERS . . If @@ -427,8 +455,9 @@ or in the current working directory. .It Cm --insecure . When viewing files with HTTPS, this option disables strict hostname and peer -checking. This allows images on sites with self-signed certificates to be -opened, but is no more secure than plain HTTP. +checking. +This allows images on sites with self-signed certificates to be opened, bu is +no more secure than plain HTTP. . .It Cm --keep-zoom-vp . @@ -437,25 +466,28 @@ When switching images, keep zoom and viewport settings . .It Cm -l , --list . -Don't display images. Analyze them and display an +Don't display images. +Analyze them and display an .Xr ls 1 - No style -listing. Useful in scripts to hunt out images of a certain -size/resolution/type etc. +listing. +Useful in scripts to hunt out images of a certain size/resolution/type etc. . .It Cm -U , --loadable . -Don't display images. Just print out their names if imlib2 can successfully -load them. +Don't display images. +Just print out their names if imlib2 can successfully load them. Returns false if at least one image failed to load. . .It Cm --magick-timeout Ar timeout . Stop trying to convert unloadable files after .Ar timeout -seconds. A negative value disables covert / magick support altogether, a value +seconds. +A negative value disables covert / magick support altogether, a value of zero causes .Nm -to try indefinitely. By default, magick support is disabled. +to try indefinitely. +By default, magick support is disabled. . Note that feh may clutter .Pa /tmp @@ -488,15 +520,18 @@ If you only care about one parameter, set the other to 0. . .It Cm -m , --montage . -Enable montage mode. Montage mode creates a new image consisting of a grid of -thumbnails of the images in the filelist. When montage mode is selected, -certain other options become available. See +Enable montage mode. +Montage mode creates a new image consisting of a grid of thumbnails of the +images in the filelist. +When montage mode is selected, certain other options become available. +See .Sx MONTAGE MODE OPTIONS . . .It Cm -w , --multiwindow . -Disable slideshow mode. With this setting, instead of opening multiple files -in slideshow mode, multiple windows will be opened; one per file. +Disable slideshow mode. +With this setting, instead of opening multiple files in slideshow mode, +multiple windows will be opened; one per file. . .It Cm --no-jump-on-resort . @@ -508,10 +543,10 @@ Don't load or show any menus. . .It Cm --no-screen-clip . -By default, window sizes are limited to the screen size. With this option, -windows will have the size of the image inside them. Note that they may -become very large this way, making them unmanageable in certain window -managers. +By default, window sizes are limited to the screen size. +With this option, windows will have the size of the image inside them. +Note that they may become very large this way, making them unmanageable +in certain window managers. . .It Cm --no-xinerama . @@ -527,23 +562,27 @@ By default, files are saved in the current working directory. . .It Cm -p , --preload . -Preload images. This doesn't mean hold them in RAM, it means run through -them and eliminate unloadable images first. Otherwise they will be removed -as you flick through. This also analyses the images to get data for use in -sorting, such as pixel size, type etc. A preload run will be automatically -performed if you specify one of these sort modes. +Preload images. +This doesn't mean hold them in RAM, it means run through them and eliminate +unloadable images first. +Otherwise they will be removed as you flick through. +This also analyses the images to get data for use in sorting, such as pixel +size, type etc. +A preload run will be automatically performed if you specify one of these +sort modes. . .It Cm -q , --quiet . -Don't report non-fatal errors for failed loads. Verbose and quiet modes are -not mutually exclusive, the first controls informational messages, the second -only errors. +Don't report non-fatal errors for failed loads. +Verbose and quiet modes are not mutually exclusive, the first controls +informational messages, the second only errors. . .It Cm -z , --randomize . When viewing multiple files in a slideshow, randomize the file list before -displaying. The list is re-randomized whenever the slideshow cycles (that is, -transitions from last to first image). +displaying. +The list is re-randomized whenever the slideshow cycles (that is, transitions +from last to first image). . .It Cm -r , --recursive . @@ -559,29 +598,32 @@ Useful to override theme options. . Reload filelist and current image after .Ar int -seconds. Useful for viewing HTTP webcams or frequently changing directories. +seconds. +Useful for viewing HTTP webcams or frequently changing directories. .Pq Note that the filelist reloading is still experimental. . .Pp . If an image is removed, .Nm -will either show the next one or quit. However, if an image still exists, but -can no longer be loaded, +will either show the next one or quit. +However, if an image still exists, but can no longer be loaded, .Nm will continue to try loading it. . .It Cm -n , --reverse . -Reverse the sort order. Use this to invert the order of the filelist. +Reverse the sort order. +Use this to invert the order of the filelist. E.g. to sort in reverse width order, use .Cm -nSwidth . . .It Cm -. , --scale-down . Scale images to fit window geometry (defaults to screen size when no geometry -was specified). Note that the window geometry is not updated when changing -images at the moment. This option is recommended for tiling window managers. +was specified). +Note that the window geometry is not updated when changing images at the moment. +This option is recommended for tiling window managers. . This option is ignored when in fullscreen and thumbnail list mode. . @@ -604,7 +646,8 @@ Default: 20 . For slideshow mode, wait .Ar float -seconds between automatically changing slides. Useful for presentations. +seconds between automatically changing slides. +Useful for presentations. Specify a negative number to set the delay .Pq which will then be Ar float No * (-1) , but start @@ -613,15 +656,16 @@ in paused mode. . .It Cm -S , --sort Ar sort_type . -The file list may be sorted according to image parameters. Allowed sort types -are: name, filename, dirname, mtime, width, height, pixels, size, format. For -sort modes other than name, filename, dirname, or mtime, a preload run will be -necessary, causing a delay proportional to the number of images in the list. +The file list may be sorted according to image parameters. +Allowed sort types are: name, filename, dirname, mtime, width, height, pixels, +size, format. +For sort modes other than name, filename, dirname, or mtime, a preload run will +be necessary, causing a delay proportional to the number of images in the list. . .Pp . -The mtime sort mode sorts images by most recently modified. To sort by oldest -first, reverse the filelist with --reverse. +The mtime sort mode sorts images by most recently modified. +To sort by oldest first, reverse the filelist with --reverse. . .It Cm -| , --start-at Ar filename . @@ -632,12 +676,14 @@ Note that at the moment, .Ar filename must match an .Pq expanded -path in the filelist. So, if the file to be matched is passed via an absolute -path in the filelist, +path in the filelist. +So, if the file to be matched is passed via an absolute path in the filelist, .Ar filename -must be an absolute path. If the file is passed via a relative path, +must be an absolute path. +If the file is passed via a relative path, .Ar filename -must be an identical relative path. This is a known issue. +must be an identical relative path. +This is a known issue. See also .Sx USAGE EXAMPLES . . @@ -647,7 +693,8 @@ Load options from config file with name .Ar theme - see .Sx THEMES CONFIG SYNTAX -for more info. Note that commandline options always override theme options. +for more info. +Note that commandline options always override theme options. The theme can also be set via the program name .Pq e.g. with symlinks , so by default @@ -663,8 +710,8 @@ Note that .Cm --fullscreen and .Cm --scale-down -do not affect the thumbnail window. They do, however, work for image windows -launched from thumbnail mode. +do not affect the thumbnail window. +They do, however, work for image windows launched from thumbnail mode. Also supports .Sx INDEX AND THUMBNAIL MODE OPTIONS as well as @@ -674,19 +721,21 @@ as well as . Set .Ar title -for windows opened from thumbnail mode. See also +for windows opened from thumbnail mode. +See also .Sx FORMAT SPECIFIERS . . .It Cm -^ , --title Ar title . -Set window title. Applies to all windows except those opened from thumbnail -mode. See +Set window title. +Applies to all windows except those opened from thumbnail mode. +See .Sx FORMAT SPECIFIERS . . .It Cm -u , --unloadable . -Don't display images. Just print out their names if imlib2 can NOT -successfully load them. +Don't display images. +Just print out their names if imlib2 can NOT successfully load them. Returns false if at least one image was loadable. . .It Cm -V , --verbose @@ -700,8 +749,8 @@ output version information and exit. .It Cm --version-sort . .Pq optional feature, $MAN_VERSCMP$ in this build -Use natural sorting for file and directory names. In this mode, filenames are -sorted as an ordinary human would expect, e.g. +Use natural sorting for file and directory names. +In this mode, filenames are sorted as an ordinary human would expect, e.g. .Qq 2.jpg comes before .Qq 10.jpg . @@ -711,8 +760,9 @@ comes before .Pq optional feature, $MAN_XINERAMA$ in this build Override .Nm Ns No 's -idea of the active Xinerama screen. May be useful in certain circumstances -where the window manager places the feh window on Xinerama screen A while +idea of the active Xinerama screen. +May be useful in certain circumstances where the window manager places the feh +window on Xinerama screen A while .Nm assumes that it will be placed on screen B. . @@ -724,10 +774,11 @@ Only set wallpaper on .Ar screen . All other screens will be filled black/white. . -This is most useful in a Xinerama configuration with -overlapping screens. For instance, assume you have two overlapping displays -(index 0 and 1), where index 0 is smaller. To center a background on the -display with index 0 and fill the extra space on index 1 black/white, use +This is most useful in a Xinerama configuration with overlapping screens. +For instance, assume you have two overlapping displays (index 0 and 1), +where index 0 is smaller. +To center a background on the display with index 0 and fill the extra space +on index 1 black/white, use .Qq --xinerama-index 0 when setting the wallpaper. . @@ -735,7 +786,8 @@ when setting the wallpaper. . Zoom images by .Ar percent -when in full screen mode or when window geometry is fixed. When combined with +when in full screen mode or when window geometry is fixed. +When combined with .Cm --auto-zoom , zooming will be limited to the specified .Ar percent . @@ -772,10 +824,11 @@ When drawing thumbnails onto the background, set their transparency level to . Use .Ar file -as background for your montage. With this option specified, the montage size -will default to the size of +as background for your montage. +With this option specified, the montage size will default to the size of .Ar file -if no size restrictions were specified. Alternatively, if +if no size restrictions were specified. +Alternatively, if .Ar file is .Qq trans , @@ -784,8 +837,8 @@ the background will be made transparent. .It Cm -X , --ignore-aspect . By default, the montage thumbnails will retain their aspect ratios, while -fitting into thumb-width/-height. This options forces them to be the size set -by +fitting into thumb-width/-height. +This options forces them to be the size set by .Cm --thumb-width No and Cm --thumb-height . This will prevent any empty space in the final montage. . @@ -819,8 +872,9 @@ without displaying it. .It Cm -s , --stretch . Normally, if an image is smaller than the specified thumbnail size, it will -not be enlarged. If this option is set, the image will be scaled up to fit -the thumbnail size. Aspect ratio will be maintained unless +not be enlarged. +If this option is set, the image will be scaled up to fit the thumbnail size. +Aspect ratio will be maintained unless .Cm --ignore-aspect is specified. . @@ -849,7 +903,8 @@ the following options can be used. . Show image information based on .Ar format -below thumbnails in index / thumbnail mode. See +below thumbnails in index / thumbnail mode. +See .Sx FORMAT SPECIFIERS . May contain newlines. . @@ -865,7 +920,8 @@ Note: If you specify image-related formats needs to load all images to calculate the dimensions of its own window. So when using them with many files, it will take a while before a .Nm -window becomes visible. Use +window becomes visible. +Use .Cm --preload to get a progress bar. . @@ -878,15 +934,16 @@ be printed. . Redraw thumbnail window every .Ar n -images. In +images. +In .Nm <= 1.5, the thumbnail image used to be redrawn after every computed thumbnail .Pq so, it updated immediately . However, since the redrawing takes quite long .Pq especially for thumbnail mode on a large filelist , this turned out to be a major performance penalty. -As a workaround, the thumbnail image is redrawn every 10th image now by -default. Set +As a workaround, the thumbnail image is redrawn every 10th image now by default. +Set .Ar n No = 1 to get the old behaviour, .Ar n No = 0 @@ -899,7 +956,8 @@ will only redraw once all thumbnails are loaded. . In many desktop environments, .Nm -can also be used as a background setter. Unless you pass the +can also be used as a background setter. +Unless you pass the .Cm --no-fehbg option, it will write a script to set the current background to .Pa ~/.fehbg . @@ -917,8 +975,8 @@ will work as well. . Note that .Nm -does not support setting the wallpaper of GNOME shell desktops. In this -environment, you can use +does not support setting the wallpaper of GNOME shell desktops. +In this environment, you can use .Qq gsettings set org.gnome.desktop.background picture-uri file:/// Ns Ar path instead. . @@ -930,10 +988,10 @@ and .Cm --bg-max , you can use .Cm --geometry -to specify an offset from one side of the screen instead of -centering the image. Positive values will offset from the left/top -side, negative values from the bottom/right. +0 and -0 are both -valid and distinct values. +to specify an offset from one side of the screen instead of centering the image. +Positive values will offset from the left/top side, negative values from the +bottom/right. ++0 and -0 are both valid and distinct values. . .Pp . @@ -951,8 +1009,8 @@ on screen 0, the second on screen 1, and so on. . Use .Cm --no-xinerama -to treat the whole X display as one screen when setting wallpapers. You -may also use +to treat the whole X display as one screen when setting wallpapers. +You may also use .Cm --xinerama-index to use .Nm @@ -962,16 +1020,16 @@ as a background setter for a specific screen. . .It Cm --bg-center . -Center the file on the background. If it is too small, it will be surrounded -by a border as specified by +Center the file on the background. +If it is too small, it will be surrounded by a border as specified by .Cm --image-bg . . .It Cm --bg-fill . Like .Cm --bg-scale , -but preserves aspect ratio by zooming the image until it fits. Either a -horizontal or a vertical part of the image will be cut off +but preserves aspect ratio by zooming the image until it fits. +Either a horizontal or a vertical part of the image will be cut off . .It Cm --bg-max . @@ -984,7 +1042,8 @@ The border color can be set using .It Cm --bg-scale . Fit the file into the background without repeating it, cutting off stuff or -using borders. But the aspect ratio is not preserved either +using borders. +But the aspect ratio is not preserved either . .It Cm --bg-tile . @@ -1024,7 +1083,8 @@ Total number of files in filelist . .It %L . -Temporary copy of filelist. Multiple uses of %L within the same format string will return the same copy. +Temporary copy of filelist. +Multiple uses of %L within the same format string will return the same copy. . .It %m . @@ -1053,7 +1113,8 @@ Number of image pixels . .It %r . -Image rotation. A half right turn equals pi. +Image rotation. +A half right turn equals pi. . .It %s . @@ -1140,8 +1201,9 @@ are the options which will be applied when the theme is used. . Note that the option parser does not behave like a normal shell: filename expansion and backslash escape sequences are not supported and passed to -feh's option parser as-is. However, quoting of arguments is respected -and can be used for arguments with whitespace. +feh's option parser as-is. +However, quoting of arguments is respected and can be used for arguments +with whitespace. . So, the sequence .Qq --info Qq foo bar @@ -1161,15 +1223,16 @@ An example entry is . .Pp . -You can use this theme in two ways. Either call +You can use this theme in two ways. +Either call .Qo .Nm -Timagemap *.jpg .Qc , or create a symbolic link to .Nm -with the name of the theme you want it to use. For the example above, -this would be +with the name of the theme you want it to use. +For the example above, this would be .Qo ln -s `which .Nm @@ -1237,8 +1300,8 @@ without any keys unbinds it (i.e. the default bindings are removed). .Pp . .Em Note : -Do not use the same keybinding for multiple actions. When binding an action -to a new key +Do not use the same keybinding for multiple actions. +When binding an action to a new key .Pq or mouse button , make sure to unbind it from its previous action, if present. .Nm @@ -1268,8 +1331,9 @@ The following actions and default key bindings can be used in an image window. If .Nm is running inside a terminal and its standard input is not used for images or -filelists, key input from the terminal is also accepted. However, terminal -input support is currently limited to most alphanumeric characters +filelists, key input from the terminal is also accepted. +However, terminal input support is currently limited to most alphanumeric +characters .Pq 0-9 a-z A-Z and some more , return and backspace. . @@ -1286,12 +1350,13 @@ Enable/Disable anti-aliasing . .It c Bq toggle_caption . -Caption entry mode. If +Caption entry mode. +If .Cm --caption-path -has been specified, then this enables caption editing. The caption at the -bottom of the screen will turn yellow and can be edited. Hit return to confirm -and save the caption, or escape to cancel editing. Note that you can insert -an actual newline into the caption using +has been specified, then this enables caption editing. +The caption at the bottom of the screen will turn yellow and can be edited. +Hit return to confirm and save the caption, or escape to cancel editing. +Note that you can insert an actual newline into the caption using .Aq Ctrl+return . . .It d Bq toggle_filenames @@ -1315,8 +1380,8 @@ Enable/Disable automatic window resize when changing images. . .It h Bq toggle_pause . -Pause/Continue the slideshow. When it is paused, it will not automatically -change slides based on +Pause/Continue the slideshow. +When it is paused, it will not automatically change slides based on .Cm --slideshow-delay . . .It i Bq toggle_info @@ -1326,19 +1391,22 @@ Toggle info display . .It k Bq toggle_keep_vp . -Toggle zoom and viewport keeping. When enabled, +Toggle zoom and viewport keeping. +When enabled, .Nm will keep zoom and X, Y offset when switching images. . .It m Bq toggle_menu . -Show menu. Use the arrow keys and return to select items, +Show menu. +Use the arrow keys and return to select items, .Aq escape to close the menu. . .It n , Ao space Ac , Ao Right Ac Bq next_img . -Show next image. Selects the next image in thumbnail mode. +Show next image. +Selects the next image in thumbnail mode. . .It o Bq toggle_pointer . @@ -1346,7 +1414,8 @@ Toggle pointer visibility . .It p , Ao BackSpace Ac , Ao Left Ac Bq prev_img . -Show previous image. Selects the previous image in thumbnail mode. +Show previous image. +Selects the previous image in thumbnail mode. . .It q , Ao Escape Ac Bq quit . @@ -1355,7 +1424,8 @@ Quit . .It r Bq reload_image . -Reload current image. Useful for webcams +Reload current image. +Useful for webcams . .It s Bq save_image . @@ -1370,8 +1440,7 @@ Toggle fullscreen . Change window size to fit current image size .Pq plus/minus zoom, if set . -In scale-down and fixed-geometry mode, this also updates the window size -limits. +In scale-down and fixed-geometry mode, this also updates the window size limits. . .It x Bq close . @@ -1388,24 +1457,28 @@ Toggle auto-zoom. .It \&[, \&] Bq prev_dir, next_dir . Jump to the first image of the previous or next sequence of images sharing -a directory name in the current filelist. Use --sort dirname if you would -like to ensure that all images in a directory are grouped together. +a directory name in the current filelist. +Use --sort dirname if you would like to ensure that all images in a directory +are grouped together. . .It < , > Bq orient_3 , orient_1 . In place editing - rotate the image 90 degrees (counter)clockwise. The rotation is lossless, but may create artifacts in some image corners when -used with JPEG images. Rotating in the reverse direction will make them go -away. See +used with JPEG images. +Rotating in the reverse direction will make them go away. +See .Xr jpegtran 1 for more about lossless JPEG rotation. . .Em Note: .Nm -assumes that this feature is used to normalize image orientation. For JPEG -images, it will unconditionally set the EXIF orientation tag to 1 +assumes that this feature is used to normalize image orientation. +For JPEG images, it will unconditionally set the EXIF orientation +tag to 1 .Pq Qq 0,0 is top left -after every rotation. See +after every rotation. +See .Xr jpegexiforient 1 for details on how to change this flag. . @@ -1566,8 +1639,8 @@ This works like the keys config file: the entries are of the form . Each .Ar binding -is a button number. It may optionally start with modifiers for things like -Control, in which case +is a button number. +It may optionally start with modifiers for things like Control, in which case .Ar binding looks like .Ar mod Ns No - Ns Ar button @@ -1677,11 +1750,12 @@ will warp your cursor to the opposite border so you can continue panning. .Pp . When clicking the zoom button and immediately releasing it, the image will be -back at 100% zoom. When clicking it and moving the mouse while holding the -button down, the zoom will be continued at the previous zoom level. The zoom -will always happen so that the pixel on which you entered the zoom mode -remains stationary. So, to enlarge a specific part of an image, click the -zoom button on that part. +back at 100% zoom. +When clicking it and moving the mouse while holding the button down, the zoom +will be continued at the previous zoom level. +The zoom will always happen so that the pixel on which you entered the zoom mode +remains stationary. +So, to enlarge a specific part of an image, click the zoom button on that part. . . .Sh SIGNALS @@ -1705,7 +1779,8 @@ Switch to previous image . .Sh USAGE EXAMPLES . -Here are some examples of useful option combinations. See also: +Here are some examples of useful option combinations. +See also: .Aq http://feh.finalrewind.org/examples/ . .Bl -tag -width indent @@ -1720,8 +1795,8 @@ Recursively show all images found in ~/Pictures and subdirectories . .It feh -rSfilename --version-sort ~/Pictures . -Same as above, but sort naturally. By default, feh will show files in the -string order of their names, meaning e.g. +Same as above, but sort naturally. +By default, feh will show files in the string order of their names, meaning e.g. .Qq foo 10.jpg will come before .Qq foo 2.jpg . @@ -1739,9 +1814,9 @@ font. .It feh -irFarial/14 -O index.jpg ~/Pictures . Make an index print of ~/Pictures and all directories below it, using 14 point -Arial to write the image info under each thumbnail. Save the image as -index.jpg and don't display it, just exit. Note that this even works without -a running X server +Arial to write the image info under each thumbnail. +Save the image as index.jpg and don't display it, just exit. +Note that this even works without a running X server . .It feh --unloadable -r ~/Pictures . @@ -1768,8 +1843,8 @@ View all images in ~/Pictures and below, sorted by width, move an image to . .It feh --start-at ./foo.jpg \&. . -View all images in the current directory, starting with foo.jpg. All other -images are still in the slideshow and can be viewed normally +View all images in the current directory, starting with foo.jpg. +All other images are still in the slideshow and can be viewed normally . .It feh --start-at foo.jpg * . @@ -1802,7 +1877,8 @@ for lossless rotation. . To view images from URLs such as http://, you need .Nm -compiled with libcurl support (enabled by default). See the +compiled with libcurl support (enabled by default). +See the .Sx VERSION section. . @@ -1813,13 +1889,15 @@ section. . On systems with giflib 5.1.2, .Nm -may be unable to load gif images. For affected mips, mipsel and arm devices, -gif support is completely broken, while on x86 / x86_64 gifs can usually -only be loaded if they are the first image in the filelist. +may be unable to load gif images. +For affected mips, mipsel and arm devices, gif support is completely +broken, while on x86 / x86_64 gifs can usually only be loaded if they are +the first image in the filelist. This appears to be a bug in giflib, see .Aq https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=813729 -for details. Workaround: Use +for details. +Workaround: Use .Cm --magick-timeout 5 .Pq or some other positive value to load gifs with imagemagick instead, or downgrade to giflib 5.1.1, or @@ -1842,8 +1920,9 @@ When enabled, .Cm --magick-timeout may clutter .Pa /tmp -with temporary files produced by ImageMagick. This happens whenever an image -is not loaded due to the conversion taking longer than the specified timeout. +with temporary files produced by ImageMagick. +This happens whenever an image is not loaded due to the conversion taking +longer than the specified timeout. . .Ss REPORTING BUGS . @@ -1899,10 +1978,11 @@ used. . THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL -THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER -IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. . .Pp . -- cgit v1.2.3 From 1e212f65c87fd634c738b4c79e1ffed5c29b039d Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 4 Apr 2018 08:35:11 +0200 Subject: Add %g and %Z format specifiers (closes #391) --- man/feh.pre | 13 +++++++++++-- src/slideshow.c | 12 ++++++++++++ 2 files changed, 23 insertions(+), 2 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index eb31f37..cc67b25 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1014,6 +1014,10 @@ Image path/filename Escaped image path/filename .Pq for use in shell commands . +.It %g +. +w,h window dimensions in pixels (mnemonic: geometry) +. .It %h . Image height @@ -1048,8 +1052,9 @@ Number of image pixels . .It \&%P . -Number of image pixels +Number of image pixels in human-readable format with k/M .Pq kilopixels / megapixels +suffix . .It %r . @@ -1087,7 +1092,11 @@ Process ID . .It %z . -current image zoom +Current image zoom, rounded to two decimal places +. +.It %Z +. +Current image zoom, higher precision . .It %% . diff --git a/src/slideshow.c b/src/slideshow.c index effdcaf..7bad2c9 100644 --- a/src/slideshow.c +++ b/src/slideshow.c @@ -468,6 +468,12 @@ char *feh_printf(char *str, feh_file * file, winwidget winwid) if (file) strncat(ret, shell_escape(file->filename), sizeof(ret) - strlen(ret) - 1); break; + case 'g': + if (winwid) { + snprintf(buf, sizeof(buf), "%d,%d", winwid->w, winwid->h); + strncat(ret, buf, sizeof(ret) - strlen(ret) - 1); + } + break; case 'h': if (file && (file->info || !feh_file_info_load(file, NULL))) { snprintf(buf, sizeof(buf), "%d", file->info->height); @@ -564,6 +570,12 @@ char *feh_printf(char *str, feh_file * file, winwidget winwid) strncat(ret, "1.00", sizeof(ret) - strlen(ret) - 1); } break; + case 'Z': + if (winwid) { + snprintf(buf, sizeof(buf), "%f", winwid->zoom); + strncat(ret, buf, sizeof(ret) - strlen(ret) - 1); + } + break; case '%': strncat(ret, "%", sizeof(ret) - strlen(ret) - 1); break; -- cgit v1.2.3 From 2693c8131af2f8749bcac4a454a860d7c61a893b Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 4 Apr 2018 08:46:04 +0200 Subject: feh(1): Fix typos --- man/feh.pre | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 22caf8c..0e76a4e 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -330,8 +330,8 @@ will read the filelist from its standard input. .It Cm -e , --font Ar font . Set global font. -Should be a truetype font, resident in the current directory or the directory, -and should be defined in the form fontname/points, like +Should be a truetype font, resident in the current directory or the font +directory, and should be defined in the form fontname/points, like .Qq myfont/12 . . .It Cm -C , --fontpath Ar path @@ -456,7 +456,7 @@ or in the current working directory. . When viewing files with HTTPS, this option disables strict hostname and peer checking. -This allows images on sites with self-signed certificates to be opened, bu is +This allows images on sites with self-signed certificates to be opened, but is no more secure than plain HTTP. . .It Cm --keep-zoom-vp @@ -1989,7 +1989,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. . -- cgit v1.2.3 From e2097364429d7f32ce7bcbe653ac6b985a864f3b Mon Sep 17 00:00:00 2001 From: orbea Date: Wed, 4 Apr 2018 19:24:34 -0700 Subject: feh.1: Silence mandoc warnings This fixes the following mandoc warnings. man -Tlint feh WARNING: skipping empty macro: No skipping empty macro (mdoc) The indicated macro has no arguments and hence no effect. man: /tmp/man1/feh.1:16:14: WARNING: skipping empty macro: No man: /tmp/man1/feh.1:16:34: WARNING: skipping empty macro: No man: /tmp/man1/feh.1:179:2: WARNING: skipping empty macro: No man: /tmp/man1/feh.1:387:48: WARNING: skipping empty macro: No man: /tmp/man1/feh.1:785:26: WARNING: skipping empty macro: No man: /tmp/man1/feh.1:785:38: WARNING: skipping empty macro: No man: /tmp/man1/feh.1:823:26: WARNING: skipping empty macro: No --- man/feh.pre | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 0e76a4e..5d115ba 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -13,7 +13,7 @@ . .Nm .Op Ar options -.Op Ar files No | Ar directories No | Ar URLs ... +.Op Ar files | Ar directories | Ar URLs ... . . .Sh VERSION @@ -176,7 +176,7 @@ after executing the action. . If -.No [ Ar title ] +.Ar [ title ] is specified .Pq note the literal Qo \&[ Qc and Qo ] Qc , .Cm --draw-actions @@ -384,7 +384,7 @@ When combined with this option only affects images opened from the thumbnail overview. The thumbnail list itself will still be windowed. . -.It Cm -g , --geometry Ar width Cm x Ar height No | Cm + Ar x Cm + Ar y | Ar width Cm x Ar height Cm + Ar x Cm + Ar y +.It Cm -g , --geometry Ar width Cm x Ar height | Cm + Ar x Cm + Ar y | Ar width Cm x Ar height Cm + Ar x Cm + Ar y . Limit (and don't change) the window size. Takes an X-style geometry @@ -782,7 +782,7 @@ on index 1 black/white, use .Qq --xinerama-index 0 when setting the wallpaper. . -.It Cm --zoom Ar percent No | Cm max No | Cm fill +.It Cm --zoom Ar percent | Cm max | Cm fill . Zoom images by .Ar percent @@ -820,7 +820,7 @@ When drawing thumbnails onto the background, set their transparency level to .Ar int .Pq 0 - 255 . . -.It Cm -b , --bg Ar file No | Cm trans +.It Cm -b , --bg Ar file | Cm trans . Use .Ar file -- cgit v1.2.3 From a255e8de6b433b817832283e59f2057163ba7206 Mon Sep 17 00:00:00 2001 From: orbea Date: Sat, 7 Apr 2018 22:11:30 -0700 Subject: feh.1: Silence mandoc warnings man -Tlint feh STYLE: no blank before trailing delimiter: Em Note: WARNING: skipping paragraph macro: Pp after Sh no blank before trailing delimiter (mdoc) The last argument of a macro that supports trailing delimiter arguments is longer than one byte and ends with a trailing delimiter. Consider inserting a blank such that the delimiter becomes a separate argument, thus moving it out of the scope of the macro. skipping paragraph macro In mdoc(7) documents, this happens - at the beginning and end of sections and subsections - right before non-compact lists and displays - at the end of items in non-column, non-compact lists - and for multiple consecutive paragraph macros. In man(7) documents, it happens - for empty P, PP, and LP macros - for IP macros having neither head nor body arguments - for br or sp right after SH or SS https://man.openbsd.org/mandoc.1 man: feh.1:1483:9: STYLE: no blank before trailing delimiter: Em Note: man: feh.1:1897:2: WARNING: skipping paragraph macro: Pp after Sh There are two warnings here. 1. This is fixed by adding a zero-width space (\&) so that the trailing delimiter character (:) is no longer at the end. This also adds this to a few other similar examples. The man page should render the same after this change. 2. Removed an extra .Pp macro as suggested by the warning, this does not change how the man page renders. --- man/feh.pre | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 5d115ba..3d335bf 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1308,7 +1308,7 @@ without any keys unbinds it (i.e. the default bindings are removed). . .Pp . -.Em Note : +.Em Note:\& Do not use the same keybinding for multiple actions. When binding an action to a new key .Pq or mouse button , @@ -1480,7 +1480,7 @@ See .Xr jpegtran 1 for more about lossless JPEG rotation. . -.Em Note: +.Em Note:\& .Nm assumes that this feature is used to normalize image orientation. For JPEG images, it will unconditionally set the EXIF orientation @@ -1657,7 +1657,7 @@ looks like . .Pp . -.Em Note : +.Em Note:\& Do not use the same button for multiple actions. .Nm does not check for conflicting bindings, so their behaviour is undefined. @@ -1894,8 +1894,6 @@ section. . .Sh BUGS . -.Pp -. On systems with giflib 5.1.2, .Nm may be unable to load gif images. -- cgit v1.2.3 From 384a6069de80e0ad8980c2b6d403b32a3e10ee83 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 18 Apr 2018 21:15:57 +0200 Subject: Document ~/.fehbg a bit more precisely --- man/feh.pre | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 3d335bf..01b6377 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -962,14 +962,17 @@ Unless you pass the option, it will write a script to set the current background to .Pa ~/.fehbg . So to have your background restored every time you start X, you can add -.Qq sh ~/.fehbg & +.Qq ~/.fehbg & to your X startup script .Pq such as Pa ~/.xinitrc . -As of +Note that +.Pq unless the wallpaper is set via the menu .Nm -2.13, this script is executable, so -.Qq ~/.fehbg & -will work as well. +saves the files and directories it was passed on the commandline, not the +files which actually ended up as wallpaper. +So, if you have randomization enabled, +.Pa ~/.fehbg +may set different wallpapers on each execution. . .Pp . -- cgit v1.2.3 From f68160e7fb3c86bfa14f8ea7faf0f3d104f4a457 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Thu, 10 May 2018 21:16:00 +0200 Subject: Only save background setting-related options in ~/.fehbg This restores pre-2.21 ~/.fehbg behaviour. Replicating the entire commandline in ~/.fehbg turned out to do more harm than good. Closes #398 --- man/feh.pre | 8 -------- src/wallpaper.c | 56 +++++++++++++++++++++++++++++++++++--------------------- 2 files changed, 35 insertions(+), 29 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 01b6377..a6b76ef 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -965,14 +965,6 @@ So to have your background restored every time you start X, you can add .Qq ~/.fehbg & to your X startup script .Pq such as Pa ~/.xinitrc . -Note that -.Pq unless the wallpaper is set via the menu -.Nm -saves the files and directories it was passed on the commandline, not the -files which actually ended up as wallpaper. -So, if you have randomization enabled, -.Pa ~/.fehbg -may set different wallpapers on each execution. . .Pp . diff --git a/src/wallpaper.c b/src/wallpaper.c index 8d15335..4eaa660 100644 --- a/src/wallpaper.c +++ b/src/wallpaper.c @@ -461,6 +461,40 @@ void feh_wm_set_bg(char *fil, Imlib_Image im, int centered, int scaled, weprintf("Can't write to %s", path); } else { fputs("#!/bin/sh\n", fp); + fputs(cmdargv[0], fp); + fputs(" --bg-", fp); + if (centered) + fputs("center", fp); + else if (scaled) + fputs("scale", fp); + else if (filled) + fputs("fill", fp); + else + fputs("tile", fp); +#ifdef HAVE_LIBXINERAMA + if (opt.xinerama) { + if (opt.xinerama_index >= 0) { + fprintf(fp, " --xinerama-index %d", opt.xinerama_index); + } + } + else { + fputs(" --no-xinerama", fp); + } +#endif /* HAVE_LIBXINERAMA */ + if (opt.geom_flags & XValue) { + fprintf(fp, " --geometry %c%d", + opt.geom_flags & XNegative ? '-' : '+', + opt.geom_flags & XNegative ? abs(opt.geom_x) : opt.geom_x); + if (opt.geom_flags & YValue) { + fprintf(fp, "%c%d", + opt.geom_flags & YNegative ? '-' : '+', + opt.geom_flags & YNegative ? abs(opt.geom_y) : opt.geom_y); + } + } + if (opt.force_aliasing) { + fputs(" --force-aliasing", fp); + } + fputc(' ', fp); if (use_filelist) { for (int i = 0; i < cmdargc; i++) { if (filelist_pos && !strcmp(FEH_FILE(filelist_pos->data)->filename, cmdargv[i])) { @@ -469,30 +503,10 @@ void feh_wm_set_bg(char *fil, Imlib_Image im, int centered, int scaled, fputs(shell_escape(absolute_path), fp); filelist_pos = filelist_pos->next; free(absolute_path); - } else { - /* argument is an option / option arg */ - fputs(shell_escape(cmdargv[i]), fp); + fputc(' ', fp); } - fputc(' ', fp); } } else if (fil) { - fputs("feh --bg-", fp); - if (centered) - fputs("center", fp); - else if (scaled) - fputs("scale", fp); - else if (filled) - fputs("fill", fp); - else - fputs("tile", fp); - - if (opt.force_aliasing) - fputs(" --force-aliasing", fp); -#ifdef HAVE_LIBXINERAMA - if (!opt.xinerama) - fputs(" --no-xinerama", fp); -#endif - fputc(' ', fp); absolute_path = feh_absolute_path(fil); fputs(shell_escape(absolute_path), fp); free(absolute_path); -- cgit v1.2.3 From e28fb4e9d5723c46b8c3c91e94e9c5789b609d80 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Fri, 11 May 2018 15:03:24 +0200 Subject: Use custom temporary directory for ImageMagick calls and clean it up afterwards --- man/feh.pre | 15 --------------- src/imlib.c | 51 ++++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 50 insertions(+), 16 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index a6b76ef..a358714 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -489,11 +489,6 @@ of zero causes to try indefinitely. By default, magick support is disabled. . -Note that feh may clutter -.Pa /tmp -with temporary files created by ImageMagick for each failed conversion attempt. -This is a known bug. -. .It Cm --max-dimension Ar width No x Ar height . Only show images with width <= @@ -1916,16 +1911,6 @@ as it could be. does not take window decorations into account and may therefore make the window slightly too large. . -.Pp -. -When enabled, -.Cm --magick-timeout -may clutter -.Pa /tmp -with temporary files produced by ImageMagick. -This happens whenever an image is not loaded due to the conversion taking -longer than the specified timeout. -. .Ss REPORTING BUGS . If you find a bug, please report it to diff --git a/src/imlib.c b/src/imlib.c index baaa64a..28dc1a6 100644 --- a/src/imlib.c +++ b/src/imlib.c @@ -304,8 +304,10 @@ static char *feh_magick_load_image(char *filename) char *basename; char *tmpname; char *sfn; + char tempdir[] = "/tmp/.feh-magick-tmp-XXXXXX"; int fd = -1, devnull = -1; int status; + char created_tempdir = 0; if (opt.magick_timeout < 0) return NULL; @@ -339,6 +341,22 @@ static char *feh_magick_load_image(char *filename) */ argv_fn = estrjoin(":", "png", sfn, NULL); + /* + * By default, ImageMagick saves (occasionally lots of) temporary files + * in /tmp. It doesn't remove them if it runs into a timeout and is killed + * by us, no matter whether we use SIGINT, SIGTERM or SIGKILL. So, unless + * MAGICK_TMPDIR has already been set by the user, we create our own + * temporary directory for ImageMagick and remove its contents at the end of + * this function. + */ + if (getenv("MAGICK_TMPDIR") == NULL) { + if (mkdtemp(tempdir) == NULL) { + weprintf("%s: ImageMagick may leave temporary files in /tmp. mkdtemp failed:", filename); + } else { + created_tempdir = 1; + } + } + if ((childpid = fork()) < 0) { weprintf("%s: Can't load with imagemagick. Fork failed:", filename); unlink(sfn); @@ -360,6 +378,11 @@ static char *feh_magick_load_image(char *filename) */ setpgid(0, 0); + if (created_tempdir) { + // no error checking - this is a best-effort code path + setenv("MAGICK_TMPDIR", tempdir, 0); + } + execlp("convert", "convert", filename, argv_fn, NULL); _exit(1); } @@ -373,13 +396,39 @@ static char *feh_magick_load_image(char *filename) sfn = NULL; if (!opt.quiet) { - weprintf("%s - Conversion took too long, skipping", filename); + weprintf("%s: Conversion took too long, skipping", filename); } } close(fd); childpid = 0; } + if (created_tempdir) { + DIR *dir; + struct dirent *de; + if ((dir = opendir(tempdir)) == NULL) { + weprintf("%s: Cannot remove temporary ImageMagick files from %s:", filename, tempdir); + } else { + while ((de = readdir(dir)) != NULL) { + if (de->d_name[0] != '.') { + char *temporary_file_name = estrjoin("/", tempdir, de->d_name, NULL); + /* + * We assume that ImageMagick only creates temporary files and + * not directories. + */ + if (unlink(temporary_file_name) == -1) { + weprintf("unlink %s:", temporary_file_name); + } + free(temporary_file_name); + } + } + if (rmdir(tempdir) == -1) { + weprintf("rmdir %s:", tempdir); + } + } + closedir(dir); + } + free(argv_fn); return sfn; } -- cgit v1.2.3 From 3c675a64a5842f0fe824a22bc9d3af025c1d17fe Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Fri, 11 May 2018 20:51:24 +0200 Subject: Update copyright notice --- man/feh.pre | 2 +- src/collage.c | 2 +- src/debug.h | 2 +- src/events.c | 2 +- src/feh.h | 2 +- src/filelist.c | 2 +- src/imlib.c | 2 +- src/index.c | 2 +- src/index.h | 2 +- src/keyevents.c | 2 +- src/list.c | 2 +- src/main.c | 2 +- src/menu.c | 2 +- src/menu.h | 2 +- src/options.c | 2 +- src/options.h | 2 +- src/signals.c | 2 +- src/slideshow.c | 2 +- src/structs.h | 2 +- src/thumbnail.c | 2 +- src/thumbnail.h | 2 +- src/timers.c | 2 +- src/wallpaper.c | 2 +- src/wallpaper.h | 2 +- src/winwidget.c | 2 +- src/winwidget.h | 2 +- 26 files changed, 26 insertions(+), 26 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index a358714..d2c2cea 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1943,7 +1943,7 @@ Make zoom options more intuitive . Copyright (C) 1999, 2000 by Paul Duncan. Copyright (C) 1999, 2000 by Tom Gilbert (and various contributors). -Copyright (C) 2010-2016 by Daniel Friesel (and even more contributors). +Copyright (C) 2010-2018 by Daniel Friesel (and even more contributors). . .Pp . diff --git a/src/collage.c b/src/collage.c index 431d3b6..2a4d9f9 100644 --- a/src/collage.c +++ b/src/collage.c @@ -1,7 +1,7 @@ /* collage.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/debug.h b/src/debug.h index eb929e3..38cf83f 100644 --- a/src/debug.h +++ b/src/debug.h @@ -1,7 +1,7 @@ /* debug.h Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/events.c b/src/events.c index 947e69f..4a24935 100644 --- a/src/events.c +++ b/src/events.c @@ -1,7 +1,7 @@ /* events.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/feh.h b/src/feh.h index 3e0cdda..009f45b 100644 --- a/src/feh.h +++ b/src/feh.h @@ -1,7 +1,7 @@ /* feh.h Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/filelist.c b/src/filelist.c index 08da331..eb8e294 100644 --- a/src/filelist.c +++ b/src/filelist.c @@ -1,7 +1,7 @@ /* filelist.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/imlib.c b/src/imlib.c index 28dc1a6..5be0539 100644 --- a/src/imlib.c +++ b/src/imlib.c @@ -1,7 +1,7 @@ /* imlib.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/index.c b/src/index.c index c8c34c5..ca1664b 100644 --- a/src/index.c +++ b/src/index.c @@ -1,7 +1,7 @@ /* index.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/index.h b/src/index.h index 08ab337..b022f1a 100644 --- a/src/index.h +++ b/src/index.h @@ -1,6 +1,6 @@ /* index.h -Copyright (C) 2011 Daniel Friesel. +Copyright (C) 2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/keyevents.c b/src/keyevents.c index 12a8eb9..689aebd 100644 --- a/src/keyevents.c +++ b/src/keyevents.c @@ -1,7 +1,7 @@ /* keyevents.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/list.c b/src/list.c index 09b23f4..2f6cf76 100644 --- a/src/list.c +++ b/src/list.c @@ -1,7 +1,7 @@ /* list.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/main.c b/src/main.c index 534b89e..f1fca24 100644 --- a/src/main.c +++ b/src/main.c @@ -1,7 +1,7 @@ /* main.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/menu.c b/src/menu.c index ddb2db1..2f8875d 100644 --- a/src/menu.c +++ b/src/menu.c @@ -1,7 +1,7 @@ /* menu.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/menu.h b/src/menu.h index 403728f..b53b32f 100644 --- a/src/menu.h +++ b/src/menu.h @@ -1,7 +1,7 @@ /* menu.h Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/options.c b/src/options.c index bc95604..8ddf2fa 100644 --- a/src/options.c +++ b/src/options.c @@ -1,7 +1,7 @@ /* options.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/options.h b/src/options.h index ed8641a..61de5dc 100644 --- a/src/options.h +++ b/src/options.h @@ -1,7 +1,7 @@ /* options.h Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/signals.c b/src/signals.c index 8a3a8f7..c08d5df 100644 --- a/src/signals.c +++ b/src/signals.c @@ -1,6 +1,6 @@ /* signals.c -Copyright (C) 2010 by Daniel Friesel +Copyright (C) 2010-2018 by Daniel Friesel Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/slideshow.c b/src/slideshow.c index 7bad2c9..0e560d8 100644 --- a/src/slideshow.c +++ b/src/slideshow.c @@ -1,7 +1,7 @@ /* slideshow.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/structs.h b/src/structs.h index 3942bc0..ce30eb9 100644 --- a/src/structs.h +++ b/src/structs.h @@ -1,7 +1,7 @@ /* structs.h Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/thumbnail.c b/src/thumbnail.c index 3e99bfb..cf38cfc 100644 --- a/src/thumbnail.c +++ b/src/thumbnail.c @@ -1,7 +1,7 @@ /* thumbnail.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/thumbnail.h b/src/thumbnail.h index f22ff77..09cd771 100644 --- a/src/thumbnail.h +++ b/src/thumbnail.h @@ -1,7 +1,7 @@ /* thumbnail.h Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/timers.c b/src/timers.c index 1cac94b..95fc9f8 100644 --- a/src/timers.c +++ b/src/timers.c @@ -1,7 +1,7 @@ /* timers.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/wallpaper.c b/src/wallpaper.c index 6aa5c6d..7cf2468 100644 --- a/src/wallpaper.c +++ b/src/wallpaper.c @@ -1,7 +1,7 @@ /* wallpaper.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/wallpaper.h b/src/wallpaper.h index 0921129..02a6997 100644 --- a/src/wallpaper.h +++ b/src/wallpaper.h @@ -1,7 +1,7 @@ /* wallpaper.h Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/winwidget.c b/src/winwidget.c index 7aae191..cd5a745 100644 --- a/src/winwidget.c +++ b/src/winwidget.c @@ -1,7 +1,7 @@ /* winwidget.c Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to diff --git a/src/winwidget.h b/src/winwidget.h index dd8489a..3d998b4 100644 --- a/src/winwidget.h +++ b/src/winwidget.h @@ -1,7 +1,7 @@ /* winwidget.h Copyright (C) 1999-2003 Tom Gilbert. -Copyright (C) 2010-2011 Daniel Friesel. +Copyright (C) 2010-2018 Daniel Friesel. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to -- cgit v1.2.3 From 2a2330ada75bed8ee0344e699887ec11a6d4473c Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Fri, 11 May 2018 21:30:25 +0200 Subject: feh(1): Fix thumbnail path --- man/feh.pre | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index d2c2cea..810e27e 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -234,9 +234,13 @@ must be between 0 and 2048 MiB and defaults to 4. . .It Cm -P , --cache-thumbnails . -Enable thumbnail caching in -.Pa ~/.thumbnails . -Only works with thumbnails <= 256x256 pixels. +Enable thumbnail caching. +Thumbnails are saved in +.Pa $XDG_CACHE_HOME/thumbnails , +which defaults to +.Pa ~/.cache/thumbnails . +Note that thumbnails are only cached if the configured thumbnail size does +not exceed 256x256 pixels. . .It Cm -K , --caption-path Ar path . @@ -1807,8 +1811,7 @@ Show 128x128 pixel thumbnails, limit window width to 1024 pixels. . .It feh -t -Sfilename -E 128 -y 128 -W 1024 -P -C /usr/share/fonts/truetype/ttf-dejavu/ -e DejaVuSans/8 ~/Pictures . -Same as above, but enable thumbnail caching in ~/.thumbnails and use a smaller -font. +Same as above, but enable thumbnail caching and use a smaller font. . .It feh -irFarial/14 -O index.jpg ~/Pictures . -- cgit v1.2.3 From b63fb7e5ebc63afc7a91e2af2f8c9145c04a121d Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Fri, 11 May 2018 21:38:30 +0200 Subject: feh(1): Note that Mod1 is now supported for terminal input --- man/feh.pre | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 810e27e..aad8c50 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1338,7 +1338,10 @@ filelists, key input from the terminal is also accepted. However, terminal input support is currently limited to most alphanumeric characters .Pq 0-9 a-z A-Z and some more , -return and backspace. +arrow keys, return and backspace. +The Alt +.Pq Mod1 +modifier is also supported. . .Bl -tag -width indent . -- cgit v1.2.3 From 1538aafffa9a99d7d4fd760cae02876066a0ad82 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Thu, 2 Aug 2018 20:35:27 +0200 Subject: Update --geometry documentation in feh(1) --- man/feh.pre | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index aad8c50..28c1132 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -394,8 +394,9 @@ Limit (and don't change) the window size. Takes an X-style geometry .Ar string like 640x480 with optional +x+y window offset. -Note that larger images will be zoomed out to fit, but you can see them at 1:1 -by clicking the zoom button. +Use +.Cm --scale-down +to scale down larger images like in fullscreen mode. . Also note that this option does not enforce the geometry, changing it by a tiling WM or manually is still possible. -- cgit v1.2.3 From fd66a0f2a1352de36fa81004325df1040d1cde98 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 5 Aug 2018 13:58:09 +0200 Subject: Update magick/dcraw/timeout documentation in feh(1) --- man/feh.pre | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 28c1132..a1698e1 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -142,8 +142,12 @@ 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. +If dcraw is available, +.Nm +also supports RAW files provided by cameras and will display the embedded +thumbnails. Use -.Cm --magick-timeout Ar num +.Cm --conversion-timeout Ar num with a non-negative value to enable it. . . @@ -483,16 +487,15 @@ Don't display images. Just print out their names if imlib2 can successfully load them. Returns false if at least one image failed to load. . -.It Cm --magick-timeout Ar timeout +.It Cm --conversion-timeout Ar timeout . Stop trying to convert unloadable files after .Ar timeout seconds. -A negative value disables covert / magick support altogether, a value -of zero causes +Negative values disable conversion altogether, zero causes .Nm to try indefinitely. -By default, magick support is disabled. +By default, conversion is disabled. . .It Cm --max-dimension Ar width No x Ar height . @@ -1902,7 +1905,7 @@ see .Aq https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=813729 for details. Workaround: Use -.Cm --magick-timeout 5 +.Cm --conversion-timeout 5 .Pq or some other positive value to load gifs with imagemagick instead, or downgrade to giflib 5.1.1, or upgrade to giflib 5.1.4. -- cgit v1.2.3 From 3ed38d4b8180f8763c4115ff2a27b0d032530f9e Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 29 Aug 2018 19:32:50 +0200 Subject: Document --on-last-slide --- man/feh.pre | 42 ++++++++++++++++++++++++++++++++++++------ 1 file changed, 36 insertions(+), 6 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index a1698e1..37abe70 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -268,12 +268,6 @@ instead. See .Sx FORMAT SPECIFIERS . . -.It Cm --cycle-once -. -Exit -.Nm -after one loop through the slideshow. -. .It Cm -G , --draw-actions . Draw the defined actions and what they do at the top-left of the image. @@ -556,6 +550,42 @@ in certain window managers. .Pq optional feature, $MAN_XINERAMA$ in this build Disable Xinerama support. . +.It Cm --on-last-slide Cm hold | Cm quit | Cm resume +. +Select behaviour when trying to select the next image on the last slide +.Pq or the previous image on the first slide +in a slide show. +. +.Pp +. +With +.Cm hold , +.Nm +will stop advancing images in this case and continue displaying the first/last +image, respectively. +This is intended for linear slide shows, especially automated ones using +.Cm --slideshow-delay . +Behaviour is unspecified when using other navigation commands than previous +and next image. +. +.Pp +. +.Cm quit +will cause +.Nm +to quit when trying to advance past the last image in the slide show. +. +.Pp +. +.Cm resume +is the default behaviour: On the last +.Pq first +image, +.Nm +will wrap around to the first +.Pq last +image. +. .It Cm -j , --output-dir Ar directory . Save files to -- cgit v1.2.3 From 602641c73512874d39011030b05bce03cc55134f Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 29 Aug 2018 19:36:30 +0200 Subject: --on-last-slide=hold is not limited to slideshow-delay --- man/feh.pre | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 37abe70..f65ccd2 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -563,8 +563,7 @@ With .Nm will stop advancing images in this case and continue displaying the first/last image, respectively. -This is intended for linear slide shows, especially automated ones using -.Cm --slideshow-delay . +This is intended for linear slide shows. Behaviour is unspecified when using other navigation commands than previous and next image. . -- cgit v1.2.3