From 6bdf2eef44b667298aa8f7bd61aa59e59050f588 Mon Sep 17 00:00:00 2001 From: Olof-Joachim Frahm Date: Wed, 3 Oct 2018 00:06:33 +0200 Subject: Use output directory for image saving command. --- 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 f65ccd2..2587501 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -589,7 +589,7 @@ image. . Save files to .Ar directory -.Pq only useful with -k . +.Pq only useful with -k , -o / -O or the save_image command . By default, files are saved in the current working directory. . .It Cm -p , --preload -- cgit v1.2.3 From 41beaa1acb1c4888ee3a3c9a014049854669a34a Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 4 Nov 2018 11:17:43 +0100 Subject: feh(1): Note that --version-sort needs --sort to be set closes #431 --- man/feh.pre | 35 +++++++++++++++++++++++++++++------ 1 file changed, 29 insertions(+), 6 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index f65ccd2..583e68f 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -688,16 +688,33 @@ in paused mode. . .It Cm -S , --sort Ar sort_type . -The file list may be sorted according to image parameters. +Sort file list 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. +For sort modes other than name, filename, dirname, or mtime, a preload run is +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. +.Cm mtime +starts with the most recently modified image, +.Cm width , height , pixels +and +.Cm size +start with the smallest. +Use +.Cm --reverse +to sort by oldest or largest first. +. +.Pp +. +For +.Cm name , filename , +and +.Cm dirname , +you can use +.Cm --version-sort +to sort numbers naturally, so that e.g. 10.jpg comes after 2.jpg. . .It Cm -| , --start-at Ar filename . @@ -781,11 +798,17 @@ 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. +When combined with +.Cm --sort name , --sort filename , +or +.Cm --sort dirname : +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 . +Note that this option only has an effect when a sort mode is set using +.Cm --sort . . .It Cm --xinerama-index Ar screen . -- cgit v1.2.3 From b13bbbfb3b8306119d86df95c147df62b4f51efe Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 4 Nov 2018 16:06:20 +0100 Subject: Remove feh-cam and gen-cam-menu --- ChangeLog | 4 ++ Makefile | 17 ----- README.md | 1 - cam/ChangeLog | 14 ---- cam/README | 45 ------------ cam/cam_bookmarks | 2 - cam/feh-cam | 195 --------------------------------------------------- cam/gen-cam-menu | 44 ------------ config.mk | 1 - man/feh-cam.pre | 57 --------------- man/gen-cam-menu.pre | 33 --------- test/mandoc.t | 2 +- 12 files changed, 5 insertions(+), 410 deletions(-) delete mode 100644 cam/ChangeLog delete mode 100644 cam/README delete mode 100644 cam/cam_bookmarks delete mode 100755 cam/feh-cam delete mode 100755 cam/gen-cam-menu delete mode 100644 man/feh-cam.pre delete mode 100644 man/gen-cam-menu.pre (limited to 'man') diff --git a/ChangeLog b/ChangeLog index 78570cf..33d21de 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +git HEAD + + * Remove deprecated webcam scripts (feh-cam and gen-cam-menu) + Sat, 27 Oct 2018 19:46:48 +0200 Daniel Friesel * Release v2.28.1 diff --git a/Makefile b/Makefile index 925e3fb..552ae4d 100644 --- a/Makefile +++ b/Makefile @@ -25,23 +25,6 @@ test-x11: all install: install-man install-doc install-bin install-font install-img install: install-icon install-examples install-applications -ifeq (${cam},1) -install: install-cam -uninstall: uninstall-cam -endif - -install-cam: - @echo installing fe-cam and gen-cam-menu - @cp man/feh-cam.1 man/gen-cam-menu.1 ${man_dir}/man1 - @chmod 644 ${man_dir}/man1/feh-cam.1 ${man_dir}/man1/gen-cam-menu.1 - @cp cam/feh-cam cam/gen-cam-menu ${bin_dir} - @chmod 755 ${bin_dir}/feh-cam ${bin_dir}/gen-cam-menu - -uninstall-cam: - rm -f ${man_dir}/man1/feh-cam.1 - rm -f ${man_dir}/man1/gen-cam-menu.1 - rm -f ${bin_dir}/feh-cam ${bin_dir}/gen-cam-menu - install-man: @echo installing manuals to ${man_dir} @mkdir -p ${man_dir}/man1 diff --git a/README.md b/README.md index 334e681..3b7be60 100644 --- a/README.md +++ b/README.md @@ -79,7 +79,6 @@ Available flags are: | Flag | Default value | Description | | :--- | :---: | :--- | | app | 0 | install icons to /usr/share, regardless of `DESTDIR` and `PREFIX, and call gtk-update-icon-cache afterwards | -| cam | 0 | install deprecated feh-cam und gen-cam-menu scripts | | curl | 1 | use libcurl to view http:// and similar images | | debug | 0 | debug build, enables `--debug` | | exif | 0 | Builtin EXIF tag display support | diff --git a/cam/ChangeLog b/cam/ChangeLog deleted file mode 100644 index 4a562bd..0000000 --- a/cam/ChangeLog +++ /dev/null @@ -1,14 +0,0 @@ -0.3 ---- -- added this changelog.. - -0.4 ---- -- added richlowe's patch. since he pretty much rewrote everything, he's -an author, not a contributor. :) -- uses "use strict" now -- uses POD for documentation -- added title support in cam bookmarks file -- cmd line flag for different bookmars file -- getoppt_long use for command-line flags -- rmeoved richlow's damn nonstandard Pod::Usage stuff diff --git a/cam/README b/cam/README deleted file mode 100644 index e67d60e..0000000 --- a/cam/README +++ /dev/null @@ -1,45 +0,0 @@ -Cam 0.4 README -============== -This document was last updated on 20010223-1620-PST. -Please see the file COPYING for licensing information. - -Description -=========== -feh-cam is a Perl wrapper for feh that simlifies viewing webcams. It uses -keyed bookmarks. Type "feh-cam --help" at the command line for usage -information. - -Webcam Information -================== -All webcam images are the property of their respective owners. If you -enjoy the cam, you should check out the page too! The initial list of -cam bookmarks (in the cam_bookmarks file) is a combination of webcams -scoured from the #E People Page (http://bma.debian.net/~bma/e-irc/), -my favorite webcams from the Stile Project's cam pages -(http://www.stileproject.com/), and additional #e people cams that -have come online since cam's original release (0.1). - -Installation -============ -- Copy the "feh-cam" script to a location in your PATH (ex /usr/bin, - /usr/local/bin, or $HOME/bin), and make sure hte execute bit on the - script is set (type "chmod a+x $HOME/.cam_bookmarks"). -- Copy the "cam_bookmarks" file to $HOME/.cam_bookmarks and make sure - cam can see it by typing "feh-cam --list". -- Optionally, modify the options inside the feh-cam script. You can pass - feh any options before the image by adjusting the $PRE variable, - and any options after the image by adjustin the $POST variable. - For example, I like to keep all cam images by default; you can enable - this behavior with the -k command line option, or enable it permanently - by adding it to the $PRE flags in feh-cam. - -About the Authors -================= -Paul Duncan , pabs on #e -http://www.pablotron.org/ - -Richard Lowe , richlowe on #e -http://www.richlowe.btinternet.co.uk/ - -...but the real credit goes to Tom Gilbert for making feh, an awesome -image viewer. :) diff --git a/cam/cam_bookmarks b/cam/cam_bookmarks deleted file mode 100644 index 8d45413..0000000 --- a/cam/cam_bookmarks +++ /dev/null @@ -1,2 +0,0 @@ -nasa_shuttle=60,http://science.ksc.nasa.gov/shuttle/countdown/video/chan2large.jpg - diff --git a/cam/feh-cam b/cam/feh-cam deleted file mode 100755 index 29b254f..0000000 --- a/cam/feh-cam +++ /dev/null @@ -1,195 +0,0 @@ -#!/usr/bin/perl -w - -use strict; -use Getopt::Long; - -############################################# -############# CAM RUN-TIME OPTIONS ########## -############################################# -my $feh = "feh"; - -# additional feh cmdline options -my $PRE = " -q -G -Twebcam -1 0 -0 1 "; -my $POST = ""; -############################################# -############################################# - -# Options -my $help = ''; -my $fullscreen = ''; -my $geometry = ''; -my $list = ''; -my $verbose = ''; -my $add = ''; -my $keep = ''; -my $deftitle = '%cCAM - %u'; -my $title = ''; -my $bp = $ENV{HOME}."/.cam_bookmarks"; -my $DEBUG = 0; - -# check args -&print_usage_and_exit unless (@ARGV); - -print STDERR "Note: feh-cam will be removed from the feh distribution in 2013.\n"; -print STDERR "Please mail derf\@finalrewind.org if you still use it.\n"; - - -# Url, Refresh, and bookmarks -my $url = ""; -my $ref = ""; -my %bms = (); - -GetOptions('help|?|h' => \$help, - 'full-screen|f|giblets-mom' => \$fullscreen, - 'list|l' => \$list, - 'geometry|g=s' => \$geometry, - 'verbose|v' => \$verbose, - 'add|a' => \$add, - 'keep-images|k|save-pr0n' => \$keep, - 'title|t=s' => \$title, - 'debug|d' => \$DEBUG, - 'bookmarks|b=s' => \$bp - ); - -my $key = shift @ARGV; - -&print_usage_and_exit if ($help); - -if ($verbose) { - $PRE .= " -V "; -} - -if ($fullscreen) { - $PRE =~ s/-w//; - $PRE .= " --full-screen --auto-zoom "; -} - -if ($geometry) { - $PRE .= " --geometry $geometry "; -} - -# if requested, add a key/url pair to bookmarks file -if ($add) { - my $mytitle = ''; - ($url,$ref,$mytitle) = @ARGV; - die "Bad key syntax\n" unless ($key && $url && $ref); - - $mytitle="" unless ($mytitle); - - open(BMF, ">>$bp") or die "Couldn't open bookmarks file \"$bp\": $!\n"; - print BMF "$key=$ref,$url \"$mytitle\"\n"; - close BMF; - print "Added URL key \"$key\" = $url, $ref.\n"; # its useful to have this even if you arent debugging --richlowe - exit 0; -} - -if ($keep) { - $PRE .= " -k "; -} - - - -# load bookmarks -open(BMF, "$bp") or die "Couldn't open bookmarks file \"$bp\": $!\n"; -foreach () { - next unless /^(.*?)=(.*)$/; - $bms{$1} = $2; - print "key=$1, url=$2\n" if ($DEBUG); -} -close BMF; - -# if requested, dump a list of key/url pair values -if ($list) { - foreach (sort keys %bms) { - my $t = $bms{$_}; - - $t =~ s/^(.+?),(.+?)(^ "(.*)"|)?$/$2/; - chomp $t; - print "$_ = $t, $1, $3\n"; - } - exit 0; -} - -# main loop -MAIN: { - do { - $title=""; - $url = $bms{$key}; - die "Couldn't find URL key \"$key.\"\n" unless($url); - - $url =~ s/^(.+?),(.+?)( "(.*)")?$/$2/; - $ref = $1; - - if ($4) { - $title = $4; - } else { - $title = $deftitle; - } - - if ($title) { - $title =~ s/\%c/$key/g; - $title =~ s/\%u/$url/g; - $title =~ s/\%r/$ref/g; - $title =~ s/\%\%/\%/g; - $title = " --title \"$title\" "; - } - - my $cmd = "$feh $PRE $title -T".$key."cam -R $ref $url $POST"; - print "$cmd\n" if ($DEBUG); - FORK: { - my $pid; - if ($pid = fork) { - # We're a daddy! :) - } elsif (defined $pid) { - # child - exec "$cmd" or die "Couldnt exec() $feh: $!\n"; - } elsif ( $! =~ /No more process/) { - sleep 5; - redo FORK; - } else { - # wtf? - die "Unrecoverable fork() error: $!\n"; - } - } - } while ($key = shift @ARGV); -} - - -sub print_usage_and_exit() { - print <, and - Richard Lowe - -Description: - A convenient webcam wrapper for feh. - -Usage: - $0 - Load the urls specified by the given keys. - key : a url key stored in the bookmarks file (\"$bp\"). - $0 <-a|--add> key url refresh - Add a key to the bookmarks file. - key : short key (ex \"jenni\"), - url : url (ex \"http://www.jennicam.org/webcam/cam.jpg\"), - refresh : refresh, in seconds (ex 120) - $0 <-l|--list> - List each url key in the bookmarks file (\"$bp\"). - $0 [-f|--full-screen] keys - Start feh in full-screen mode (aka --giblets-mom \"viewing\" mode). - $0 [-k|--keep-images] keys - Save each image in the current directory (aka --save-pr0n). - $0 [-g|--geometry] xxx - Use window geometry xxx (e.g. 640x480). - $0 [-v|--verbose] options - Start feh in verbose mode (feh -V). - $0 <-h|-?|--help> - Display usage information (this screen). - -Notes: -Thanks to giblet for feh, an awesome image and webcam viewing program, -and raster for Imlib2. -END_USAGE - exit(-1); -} - diff --git a/cam/gen-cam-menu b/cam/gen-cam-menu deleted file mode 100755 index 710070b..0000000 --- a/cam/gen-cam-menu +++ /dev/null @@ -1,44 +0,0 @@ -#!/bin/sh - -###################################################################### -# gen_cam_menu.sh 0.1 # -# by Paul Duncan # -# # -# This script will generate a menu of cam bookmarks for # -# Enlightenment DR0.16.x. TYou can safely run this script more than # -# once; it won't add an another entry to the left-click menu if it's # -# already been run once. It doesn't delete any existing menu # -# entries, and it backs up your existing menu files as well. (just # -# in case I screwed up.. hehe). THe two variables below allow you # -# rename the left-click menuitem, and the menu title. # -# # -# # -MENU_ITEM="Webcams"; # -MENU_TITLE="Webcam List"; # -BMARKS=$HOME"/.cam_bookmarks"; # -# # -###################################################################### - - -C_MENUFILE="webcam.menu"; -F_MENUFILE="file.menu"; -C_MENU=$HOME"/.enlightenment/"$C_MENUFILE; -F_MENU=$HOME"/.enlightenment/"$F_MENUFILE; - -# make backups, just in case -cp -f $C_MENU $C_MENU"-cam_menu.backup" -cp -f $F_MENU $F_MENU"-cam_menu.backup" - -echo "Note: gen-cam-menu will be removed from the feh distribution by 2013." > /dev/stderr -echo "Please mail derf@finalrewind.org if you still use it." > /dev/stderr - -# generate cam menu -echo "Generating \""$C_MENU"\"."; -echo "\"$TITLE\"" > "$C_MENU"; -cat $BMARKS | perl -e "while (<>) { /(.*?)=/; \$keys{\$1}=\"1\"; } foreach(sort keys %keys) { /(.)(.*$)/; print \"\\\"\".uc(\$1).\"\$2\\\" NULL exec \\\"feh-cam \$1\$2\\\"\\n\"; }">> $C_MENU; - -# add entry to file menu if there isn't one -echo "Generating \""$F_MENU"\"."; -perl -i -e "\$already_there=0; while (<>) { \$already_there++ if (/$MENU_ITEM/); print \"\\\"$MENU_ITEM\\\" NULL menu \\\"$C_MENUFILE\\\"\\n\" if (!\$already_there&&/Restart/); print; }" $F_MENU; - -echo "Done."; diff --git a/config.mk b/config.mk index 226c612..43cc394 100644 --- a/config.mk +++ b/config.mk @@ -2,7 +2,6 @@ PACKAGE ?= feh VERSION ?= ${shell git describe --dirty} app ?= 0 -cam ?= 0 curl ?= 1 debug ?= 0 exif ?= 0 diff --git a/man/feh-cam.pre b/man/feh-cam.pre deleted file mode 100644 index 4a02753..0000000 --- a/man/feh-cam.pre +++ /dev/null @@ -1,57 +0,0 @@ -.Dd $DATE$ -.Dt FEH-CAM 1 -.Os -. -.Sh NAME -.Nm feh-cam -.Nd utility for viewing live webcam images -.Sh SYNOPSIS -.Nm -.Op Ar options -.Ar keys -. -.Sh VERSION -This manual documents feh-cam, shipped with feh version $VERSION$ -. -.Sh DEPRECATION WARNING -. -This tool will be removed from the feh distribution by 2013. -. -.Pp -. -If you still use it, please contact me at -.Aq derf@finalrewind.org -. -.Sh DESCRIPTION -.Nm -is a perl wrapper for feh which simplifies viewing webcams using keyed -bookmarks. It helps manage viewing your favourite webcam sites with feh. -. -.Sh OPTIONS -.Bl -tag -width indent -.It Cm -a , --add Ar key url refresh -Add -.Ar url -as -.Ar key -to the bookmarks file; when viewing, reload it every -.Ar refresh -seconds -.It Cm -l , --list -List each url / key pair in the bookmarks file -.It Cm -f , --full-screen -Start feh in full-screen mode -.It Cm -k , --keep-images -Save each webcam image in the current directory -.It Cm -g , --geometry Ar width No x Ar height -Use window geometry -.Ar width No x Ar height -.It Cm -v , --verbose -Start feh in verbose mode -.El -. -.Sh FILES -The bookmarks are stored in -.Pa ~/.cam_bookmarks -.Sh SEE ALSO -.Xr feh 1 diff --git a/man/gen-cam-menu.pre b/man/gen-cam-menu.pre deleted file mode 100644 index 18064f1..0000000 --- a/man/gen-cam-menu.pre +++ /dev/null @@ -1,33 +0,0 @@ -.Dd $DATE$ -.Dt GEN-CAM-MENU 1 -.Os -. -.Sh NAME -.Nm gen-cam-menu -.Nd utility for updating Enlightenment user menus for feh-cam -.Sh SYNOPSIS -.Nm -. -.Sh VERSION -This manual documents gen-cam-menu, shipped with feh version $VERSION$ -. -.Sh DEPRECATION WARNING -. -This tool will be removed from the feh distribution by 2013. -. -.Pp -. -If you still use it, please contact me at -.Aq derf@finalrewind.org -. -.Sh DESCRIPTION -.Nm -is a shell script which creates Enlightenment user menu entries for the -bookmarks stored by -.Xr feh-cam 1 -in -.Pa ~/.enlightenment/ . -. -.Sh SEE ALSO -.Xr feh 1 , -.Xr feh-cam 1 diff --git a/test/mandoc.t b/test/mandoc.t index 638c5e9..48b8443 100755 --- a/test/mandoc.t +++ b/test/mandoc.t @@ -20,7 +20,7 @@ SKIP: { skip( 'mandoc not installed', 3 ); } - for my $file ( 'feh', 'feh-cam', 'gen-cam-menu' ) { + for my $file ('feh') { qx{mandoc -Tlint -Werror man/${file}.1}; is( $?, 0, "${file}.1: Valid mdoc syntax" ); } -- cgit v1.2.3 From bfb069600de801007b51345f036fe92cb5ab5be3 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 4 Nov 2018 22:25:16 +0100 Subject: Document new editing behaviour --- man/feh.pre | 28 ++++++++++++++++++++++++---- 1 file changed, 24 insertions(+), 4 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 583e68f..34220a2 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -289,6 +289,12 @@ Show overlay texts .Pq as created by Cm --draw-filename No et al on a semi-transparent background to improve their readability . +.It Cm --edit +. +Enable basic editing of files. This makes rotation and mirroring +.Pq bound to Qo < Qc , Qo > Qc , Qo | Qc , and Qo _ Qc by default +change the underlying file and not just its displayed content. +. .It Cm -f , --filelist Ar file . This option is similar to the playlists used by music software. @@ -1525,8 +1531,14 @@ 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 +rotate the image 90 degrees (counter)clockwise. +. +.Pp +. +When +.Cm --edit +is used, this also rotates the image in the underlying file. +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 @@ -1546,11 +1558,19 @@ for details on how to change this flag. . .It _ Bq flip . -In place editing - vertical flip +Vertically flip image. +When +.Cm --edit +is used, this also flips the image in the underlying file +.Pq see above . . .It | Bq mirror . -In place editing - horizontal flip +Horizontally flip image. +When +.Cm --edit +is used, this also flips the image in the underlying file +.Pq see above . . .It 0 .. 9 Bq action_0 .. action_9 . -- cgit v1.2.3 From 7b80962e541ddc156762aa9d53cd6f00864b9178 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Tue, 6 Nov 2018 21:13:56 +0100 Subject: Improve parts of feh(1) --- man/feh.pre | 36 +++++++++++++++++++++--------------- 1 file changed, 21 insertions(+), 15 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 34220a2..8a72f07 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -382,8 +382,7 @@ only affects smaller images and never scales larger than necessary to fit the 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. +of 100, in which case images will always be shown at 100% zoom. . .Pp . @@ -394,17 +393,17 @@ The thumbnail list itself will still be windowed. . .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 -.Ar string -like 640x480 with optional +x+y window offset. -Use +Use a fixed window size as specified in the X-style geometry +.Ar string , +e.g. 640x480. +An optional +x+y window offset can be specified. +Combine with .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 +Note that this option does not enforce the window size; 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. +However, auto-resize remains disabled. . .It Cm -Y , --hide-pointer . @@ -421,8 +420,9 @@ Accepted values: default, checks, or an XColor . 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. +In fullscreen and background setting mode, +.Cm checks +is not accepted and the default is black. . .It Cm -i , --index . @@ -489,13 +489,19 @@ Returns false if at least one image failed to load. . .It Cm --conversion-timeout Ar timeout . -Stop trying to convert unloadable files after +.Nm +can use ImageMagick to try converting unloadable files into a supportad +file format. +As this can take a long time, it is disabled by default. +Set .Ar timeout -seconds. -Negative values disable conversion altogether, zero causes +to a non-negative value to enable it. +A positive value +specifies after how many seconds conversion attempts should be aborted, +zero causes .Nm to try indefinitely. -By default, conversion is disabled. +Negative values restore the default by disabling conversion altogether. . .It Cm --max-dimension Ar width No x Ar height . -- cgit v1.2.3 From 0c4d8edf95abeacfa0d98d34d05d34fee051362c Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 7 Nov 2018 20:15:26 +0100 Subject: Further manpage refinements --- man/feh.pre | 74 ++++++++++++++++++++++++++++--------------------------------- 1 file changed, 34 insertions(+), 40 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 8a72f07..35ff062 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -37,8 +37,7 @@ 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 -.Pq unless arguments or a filelist are specified , +When no file arguments or filelists are specified, .Nm displays all files in the current directory. . @@ -96,7 +95,7 @@ and its size can be limited by height, width or both. . 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 +size and dimensions, 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. @@ -148,7 +147,7 @@ also supports RAW files provided by cameras and will display the embedded thumbnails. Use .Cm --conversion-timeout Ar num -with a non-negative value to enable it. +with a non-negative value to enable support for these formats. . . .Sh OPTIONS @@ -376,7 +375,7 @@ to get a progress bar. . Make the window fullscreen. Note that in this mode, large images will always be scaled down to fit the -screen, +screen, and .Cm --zoom Ar zoom only affects smaller images and never scales larger than necessary to fit the screen size. @@ -463,10 +462,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. +When viewing files with HTTPS, this option disables all certificate checks. It +allows images on sites with self-signed or expired certificates to be opened, +but is no more secure than plain HTTP. . .It Cm --keep-zoom-vp . @@ -635,8 +633,9 @@ to the content of those directories, all the way down to the bottom level. . .It Cm --no-recursive . -Don't recursively expand any directories (enabled by default). -Useful to override theme options. +Don't recursively expand any directories. +This is the default, but this option is useful to override themes containing +.Cm --recursive . . .It Cm -R , --reload Ar int . @@ -644,7 +643,7 @@ Reload filelist and current image after .Ar int seconds. Useful for viewing HTTP webcams or frequently changing directories. -.Pq Note that the filelist reloading is still experimental. +.Pq Note that filelist reloading is still experimental. . .Pp . @@ -680,10 +679,10 @@ In tiling environments, this also causes the image to be centered in the window. Scroll .Ar count pixels whenever scroll_up, scroll_down, scroll_left or scroll_right is pressed. -Note that this option accepts negative numbers in case you need to inverse the -scroll direction; see +Note that this option accepts negative numbers in case you need to reverse the +scroll direction. See .Sx KEYS CONFIG SYNTAX -to change it permanently. +for how to reverse it permanently. Default: 20 . .It Cm -D , --slideshow-delay Ar float @@ -1001,20 +1000,14 @@ be printed. . 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. +images while generating thumbnails. +Redrawing takes quite long, so the default is 10. Set .Ar n No = 1 -to get the old behaviour, -.Ar n No = 0 -will only redraw once all thumbnails are loaded. +to update the thumbnail window immediately. +With +.Ar n No = 0 , +there will only be one redraw once all thumbnails are loaded. . .El . @@ -1250,7 +1243,7 @@ If the files are not found in that directory, it will also try All config files treat lines starting with a .Qq # character as comments. -Note that mid-line comments are not supported. +Comments at the end of a line are not supported. . . .Sh THEMES CONFIG SYNTAX @@ -1473,7 +1466,7 @@ 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, +Use the arrow keys and return to select items, and .Aq escape to close the menu. . @@ -1635,7 +1628,7 @@ Scroll up .It Ao keypad Down Ac , Ao Ctrl+Down Ac Bq scroll_down . Scroll down. -Note that the scroll keys work without anti-aliasing for performance reasons, +Note that the scroll keys work without anti-aliasing for performance reasons; hit the render key after scrolling to antialias the image. . .It Aq Alt+Left Bq scroll_left_page @@ -1869,7 +1862,7 @@ Switch to previous image . Here are some examples of useful option combinations. See also: -.Aq http://feh.finalrewind.org/examples/ +.Aq https://feh.finalrewind.org/examples/ . .Bl -tag -width indent . @@ -1941,7 +1934,7 @@ Same as above . Show some EXIF information, extracted by exifprobe/exifgrep . -.It feh --action 'rm %F' -rl --max-dim 1000x800 +.It feh --action 'rm %F' -rl --max-dimension 1000x800 . Recursively remove all images with dimensions below or equal to 1000x800 pixels from the current directory. @@ -1951,23 +1944,24 @@ from the current directory. . .Sh DEPENDENCIES . +When +.Cm --edit +is used, .Nm -requires the +needs the .Cm jpegtran and .Cm jpegexiforient binaries .Pq usually distributed in Qo libjpeg-progs Qc or similar -for lossless rotation. +for lossless JPEG rotation. . .Pp . -To view images from URLs such as http://, you need +To view images from URLs such as http://, .Nm -compiled with libcurl support (enabled by default). -See the -.Sx VERSION -section. +must be compiled with libcurl support. +It is $MAN_CURL$ in this build . . .Sh BUGS @@ -2074,4 +2068,4 @@ Tom Gilbert .Pp . See also: -http://feh.finalrewind.org +https://feh.finalrewind.org -- cgit v1.2.3 From 61f83c411202b089752f8d1002c0f325f518a4f8 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Thu, 8 Nov 2018 20:42:37 +0100 Subject: Change default toggle_fullscreen key to "f" This is in line with other software. save_filelist now defaults to "L". --- ChangeLog | 3 +++ man/feh.pre | 14 +++++++------- src/keyevents.c | 4 ++-- 3 files changed, 12 insertions(+), 9 deletions(-) (limited to 'man') diff --git a/ChangeLog b/ChangeLog index f2ec192..bbfab1e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,6 +4,9 @@ git HEAD * Remove deprecated collage mode (-c/--collage) * Remove deprecated option --cycle-once (use --on-last-slide=quit instead) * Remove deprecated option --menu-bg + * Change default save_filelist key from "f" to "L" (mnemonic: fileList) + * Change default toggle_fullscreen key from "v" to "f" as this is also + used by mplayer, mpv and similar * flip and rotation (keys "<", ">", "|", and "_") no longer change the underlying file. This leaves delete ("Ctrl+Delete") as the only destructive action which is enabled by default diff --git a/man/feh.pre b/man/feh.pre index 35ff062..f6db8c4 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1436,10 +1436,9 @@ Toggle filename display .Pq optional feature, $MAN_EXIF$ in this build Toggle EXIF tag display . -.It f Bq save_filelist +.It f Bq toggle_fullscreen . -Save the current filelist as -.Qq feh_PID_ID_filelist +Toggle fullscreen . .It g Bq toggle_fixed_geometry . @@ -1463,6 +1462,11 @@ When enabled, .Nm will keep zoom and X, Y offset when switching images. . +.It L Bq save_filelist +. +Save the current filelist as +.Qq feh_PID_ID_filelist +. .It m Bq toggle_menu . Show menu. @@ -1499,10 +1503,6 @@ Useful for webcams Save the current image as .Qq feh_PID_ID_FILENAME . -.It v Bq toggle_fullscreen -. -Toggle fullscreen -. .It w Bq size_to_image . Change window size to fit current image size diff --git a/src/keyevents.c b/src/keyevents.c index 43bc82a..6c2f06e 100644 --- a/src/keyevents.c +++ b/src/keyevents.c @@ -195,10 +195,10 @@ void init_keyevents(void) { feh_set_kb("toggle_caption" , 0, XK_c, 0, 0, 0, 0); feh_set_kb("toggle_pause" , 0, XK_h, 0, 0, 0, 0); feh_set_kb("toggle_menu" , 0, XK_m, 0, 0, 0, 0); - feh_set_kb("toggle_fullscreen" , 0, XK_v, 0, 0, 0, 0); + feh_set_kb("toggle_fullscreen" , 0, XK_f, 0, 0, 0, 0); feh_set_kb("reload_image" , 0, XK_r, 0, 0, 0, 0); feh_set_kb("save_image" , 0, XK_s, 0, 0, 0, 0); - feh_set_kb("save_filelist" , 0, XK_f, 0, 0, 0, 0); + feh_set_kb("save_filelist" , 0, XK_L, 0, 0, 0, 0); feh_set_kb("orient_1" , 0, XK_greater, 0, 0, 0, 0); feh_set_kb("orient_3" , 0, XK_less, 0, 0, 0, 0); feh_set_kb("flip" , 0, XK_underscore, 0, 0, 0, 0); -- cgit v1.2.3 From c859236dea93430928e318dde5850cc5c335e46c Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 18 Nov 2018 15:52:47 +0100 Subject: Improve README and feh(1) introduction --- README.md | 75 ++++++++++++++++++++++++++++--------------------------------- man/feh.pre | 25 +++++++++------------ 2 files changed, 44 insertions(+), 56 deletions(-) (limited to 'man') diff --git a/README.md b/README.md index 58a173c..9f2e5dc 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,21 @@ [![build status](https://travis-ci.org/derf/feh.svg?branch=master)](https://travis-ci.org/derf/feh) -# feh -Imlib2 based image viewer +Feh – Image viewer and Cataloguer --- - * https://feh.finalrewind.org/ - * #feh on irc.oftc.net +feh is a light-weight, configurable and versatile image viewer. +It is aimed at command line users, but can also be started from graphical file +managers. Apart from viewing images, it can compile text and thumbnail +listings, show (un)loadable files, set X11 backgrounds, and more. + +Features include filelists, various image sorting modes, custom action scripts, +and image captions. feh can be controlled by configurable keyboard and mouse +shortcuts, terminal input and signals. When no file arguments or filelists are +specified, feh displays all files in the current directory. + +For more information, please refer to the [feh +website](https://feh.finalrewind.org/) or read the [feh +manual](https://man.finalrewind.org/1/feh/). Dependencies --- @@ -21,11 +31,10 @@ If built with exif=1: * libexif-dev * libexif12 -Recommended +Recommended Binaries --- - * jpegtran (supplied by the jpeg library, for lossless image rotation) - * convert (supplied by ImageMagick, can be used to load unsupported formats) + * convert (supplied by ImageMagick, can be used to load image formats not supported by Imlib2) Installation --- @@ -45,24 +54,23 @@ $ sudo make install **Explanation:** feh ships some icons and an X11 desktop entry, which allow it to be used from file managers, desktop menus and similar. However, installing -icons to /usr/local/share/... does not seem to work reliable in all cases. +icons to /usr/local/share/... does not seem to work reliably. Because of this, when using "make install app=1", feh will install its icons to /usr/share/..., even though they technically belong into /usr/local. - -ZSH Completion for feh is available [here](https://git.finalrewind.org/zsh/plain/etc/completions/_feh) +[ZSH completion for +feh](https://git.finalrewind.org/zsh/plain/etc/completions/_feh) is also +available. Make flags ---------- -Flags can be used to control the build and installation process. - -e.g. +feh's build process uses make flags to enable/disable optional features and +fine-tune the build and installation process. They can be passed as **make** +arguments or set as environment variables, like so: ```bash make flag=bool -``` -```bash make install flag=bool ``` or @@ -71,9 +79,8 @@ export flag=bool make && make install ``` -For example, `make xinerama=0 debug=1` will disable Xinerama support and produce a debug build. - -Available flags are: +The following flags are respected by the makefile. A default value of **1** +indicates that the corresponding feature is enabled by default. | Flag | Default value | Description | | :--- | :---: | :--- | @@ -86,8 +93,8 @@ Available flags are: | 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**, **verscmp**, and **Xinerama** are enabled. -All other flags are disabled. +For example, `make xinerama=0 debug=1` will disable Xinerama support and +produce a debug build; libcurl and natural sorting support will remain enabled. Additionally, the standard variables `PREFIX` and `DESTDIR` are supported. @@ -97,8 +104,8 @@ will be installed. It must be set both during `make` and `make install`. **DESTDIR _(default: empty)_** sets the installation root during "make install". It is mostly useful for package maintainers. -**Note:** config.mk is designed so that in most cases, you can set environment -variables instead of editing it. E.g.: +**Note:** Defaults are specified in `config.mk`. It is designed so that in most +cases, you can set environment variables instead of editing it. E.g.: ```bash CFLAGS='-g -Os' make @@ -113,26 +120,12 @@ Builtin EXIF support is maintained by Dennis Real, [here](https://github.com/rea Testing (non-X) --------------- -```bash -$ make test -``` - -Requires **perl >= 5.10** with `Test::Command`. The tests are non-interactive and -work without X, so they can safely be run even on a headless buildserver. - -Testing (X) ------------ - -Requires - * import (usually supplied by imagemagick) - * perl >= 5.10 with GD, Test::More and X11::GUITest - * twm - * Xephyr +The non-X11 parts of feh can be automatically tested by running ```bash -$ make test-x11 +$ make test ``` - -**_Be aware that this is quite experimental, so far the X-tests have only been -run on one machine. So they may or may not work for you._** +This requires **perl >= 5.10** and the perl module `Test::Command`. Tests are +non-interactive and do not require a running X11, so they can safely be run on +a headless buildserver. diff --git a/man/feh.pre b/man/feh.pre index f6db8c4..00bca66 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -32,27 +32,22 @@ $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 -.Pq graphical -file managers to view an image. -When no file arguments or filelists are specified, -.Nm -displays all files in the current directory. +is a light-weight, configurable and versatile image viewer. +It is aimed at command line users, but can also be started from graphical file +managers. +Apart from viewing images, it can compile text and thumbnail +listings, show (un)loadable files, set X11 backgrounds, and more. . .Pp . +Features include filelists, various image sorting modes, custom action scripts, +and image captions. .Nm -supports filelists, various image sorting modes, image captions, HTTP and more. -It can be controlled by configurable keyboard and mouse shortcuts, terminal +can be controlled by configurable keyboard and mouse shortcuts, terminal input and signals. -. -.Pp -. -In many desktop environments, +When no file arguments or filelists are specified, .Nm -can also be used as wallpaper setter. +displays all files in the current directory. . .Pp . -- cgit v1.2.3 From 08b881a1ee8c3720004fccc1bf1e640995aff184 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 18 Nov 2018 19:48:47 +0100 Subject: feh(1): Sort options lexically --- man/feh.pre | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 00bca66..7ff69cf 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -254,6 +254,22 @@ and viewing image the caption will be looked for in .Qq images/captions/foo.jpg.txt . . +.It Cm --conversion-timeout Ar timeout +. +.Nm +can use ImageMagick to try converting unloadable files into a supportad +file format. +As this can take a long time, it is disabled by default. +Set +.Ar timeout +to a non-negative value to enable it. +A positive value +specifies after how many seconds conversion attempts should be aborted, +zero causes +.Nm +to try indefinitely. +Negative values restore the default by disabling conversion altogether. +. .It Cm -L , --customlist Ar format . Don't display images, print image info according to @@ -445,6 +461,12 @@ is set to the output will not be displayed by default, but has to be enabled by the toggle_info key. . +.It Cm --insecure +. +When viewing files with HTTPS, this option disables all certificate checks. It +allows images on sites with self-signed or expired certificates to be opened, +but is no more secure than plain HTTP. +. .It Cm -k , --keep-http . When viewing files using HTTP, @@ -455,12 +477,6 @@ specified by .Cm --output-dir , or in the current working directory. . -.It Cm --insecure -. -When viewing files with HTTPS, this option disables all certificate checks. It -allows images on sites with self-signed or expired certificates to be opened, -but is no more secure than plain HTTP. -. .It Cm --keep-zoom-vp . When switching images, keep zoom and viewport settings @@ -480,22 +496,6 @@ 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 --conversion-timeout Ar timeout -. -.Nm -can use ImageMagick to try converting unloadable files into a supportad -file format. -As this can take a long time, it is disabled by default. -Set -.Ar timeout -to a non-negative value to enable it. -A positive value -specifies after how many seconds conversion attempts should be aborted, -zero causes -.Nm -to try indefinitely. -Negative values restore the default by disabling conversion altogether. -. .It Cm --max-dimension Ar width No x Ar height . Only show images with width <= -- cgit v1.2.3 From 310432883fb3712acd31af4570618454e9cdcd59 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 18 Nov 2018 20:14:13 +0100 Subject: feh(1): --output-dir does not affect -o / -O --- man/feh.pre | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index f59d082..173410e 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -594,7 +594,9 @@ image. . Save files to .Ar directory -.Pq only useful with -k , -o / -O or the save_image command . +when using +.Cm --keep-http +or the save_image command. By default, files are saved in the current working directory. . .It Cm -p , --preload -- cgit v1.2.3 From 55c27c4babcf63989192f930ba7a75dac691e1e5 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 18 Nov 2018 21:26:43 +0100 Subject: --start-at: Compare basenames if exact match failed This more closely resembles the expected behaviour of --start-at, but may lead to mismatches if several files in the filelist have the same basename. Closes #206 Related to #372 and #420 --- man/feh.pre | 23 ++++++++++------------- src/slideshow.c | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 56 insertions(+), 13 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 173410e..e401ab5 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -729,20 +729,17 @@ to sort numbers naturally, so that e.g. 10.jpg comes after 2.jpg. Start the filelist at .Ar filename . . -Note that at the moment, +If you use relative paths in your filelist, .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, -.Ar filename -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. -See also -.Sx USAGE EXAMPLES . +should also be a relative path. +If you use absolute paths, it should also be an absolute path. +. +If +.Nm +cannot find an exact match, it will compare basenames +.Pq filenames without the directory suffix . +Note that this may lead to mismatches if several files in your filelist +have the same basename. . .It Cm -T , --theme Ar theme . diff --git a/src/slideshow.c b/src/slideshow.c index 145bee1..145ced1 100644 --- a/src/slideshow.c +++ b/src/slideshow.c @@ -37,6 +37,24 @@ void init_slideshow_mode(void) int success = 0; gib_list *l = filelist, *last = NULL; + /* + * In theory, --start-at FILENAME is simple: Look for a file called + * FILENAME, start the filelist there, done. + * + * In practice, there are cases where this isn't sufficient. For instance, + * a user running 'feh --start-at hello.jpg /tmp' will expect feh to start + * at /tmp/hello.jpg, as if they had used + * 'feh --start-at /tmp/hello.jpg /tmp'. Similarly, XDG Desktop files + * may lead to the invocation 'feh --start-at /tmp/hello.jpg .' in /tmp, + * expecting the behaviour of 'feh --start-at ./hello.jpg .'. + * + * Since a good user experience is not about being technically correct, but + * about delivering the expected behaviour, we do some fuzzy matching + * here. In the worst case, this will cause --start-at to start at the + * wrong file. + */ + + // Try finding an exact filename match first for (; l && opt.start_list_at; l = l->next) { if (!strcmp(opt.start_list_at, FEH_FILE(l->data)->filename)) { opt.start_list_at = NULL; @@ -44,6 +62,34 @@ void init_slideshow_mode(void) } } + /* + * If it didn't work (opt.start_list_at is still set): Fall back to + * comparing just the filenames without directory prefixes. This may lead + * to false positives, but for now that's just the way it is. + */ + if (opt.start_list_at) { + char *current_filename; + char *start_at_filename = strrchr(opt.start_list_at, '/'); + if (start_at_filename) { + start_at_filename++; // We only care about the part after the '/' + } else { + start_at_filename = opt.start_list_at; + } + for (l = filelist; l && opt.start_list_at; l = l->next) { + current_filename = strrchr(FEH_FILE(l->data)->filename, '/'); + if (current_filename) { + current_filename++; // We only care about the part after the '/' + } else { + current_filename = FEH_FILE(l->data)->filename; + } + if (!strcmp(start_at_filename, current_filename)) { + opt.start_list_at = NULL; + break; + } + } + } + + // If that didn't work either, we're out of luck. if (opt.start_list_at) eprintf("--start-at %s: File not found in filelist", opt.start_list_at); -- cgit v1.2.3 From 391a9bfd489d3f2e0cc74a2f698938b3e621d25b Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Mon, 19 Nov 2018 18:34:31 +0100 Subject: --start-at: Auto-load directory when no other files are specified This changes the behaviour of "feh --start-at FILENAME" as follows: Previously, this would cause feh to load all files in the current working directory, since no files or filelists were specified on the command line. Now this is a special case: feh will extract the directory component from FILENAME, load all files in that directory, and display FILENAME. This way, it's possible to use "feh --start-at ~%f" in XDG Desktop files and browse files in feh using the prev/next keys Closes #372 Closes #420 --- man/feh.pre | 28 +++++++++++++++++++++------- src/options.c | 13 +++++++++++++ 2 files changed, 34 insertions(+), 7 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index e401ab5..d5d7cbf 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -45,7 +45,9 @@ and image captions. .Nm can be controlled by configurable keyboard and mouse shortcuts, terminal input and signals. -When no file arguments or filelists are specified, +When no file arguments or filelists are specified and +.Cm --start-at +is not used, .Nm displays all files in the current directory. . @@ -728,8 +730,20 @@ to sort numbers naturally, so that e.g. 10.jpg comes after 2.jpg. . Start the filelist at .Ar filename . +If no files or filelists were specifed on the commandline, +.Nm +will first load all files from the directory in which +.Ar filename +resides. +This way, it's possible to look at a specific image and use the next / prev +keys to browse through the directory. +See +.Sx USAGE EXAMPLES +for examples. +. +.Pp . -If you use relative paths in your filelist, +Note: If you use relative paths in your filelist, .Ar filename should also be a relative path. If you use absolute paths, it should also be an absolute path. @@ -738,7 +752,7 @@ If .Nm cannot find an exact match, it will compare basenames .Pq filenames without the directory suffix . -Note that this may lead to mismatches if several files in your filelist +This may lead to mismatches if several files in your filelist have the same basename. . .It Cm -T , --theme Ar theme @@ -1915,14 +1929,14 @@ automatically change to the next image after 5 seconds 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 \&. +.It feh --start-at ~/Pictures/foo.jpg . -View all images in the current directory, starting with foo.jpg. +View all images in ~/Pictures, starting with foo.jpg. All other images are still in the slideshow and can be viewed normally . -.It feh --start-at foo.jpg * +.It feh --start-at ~/Pictures/foo.jpg ~/Pictures . -Same as above +Same as above. . .It feh --info \&"exifgrep '\&(Model\&|DateTimeOriginal\&|FNumber\&|ISO\&|Flash\&)' %F \&| cut -d \&. -f 4-\&" \&. . diff --git a/src/options.c b/src/options.c index 894e29f..333c8c7 100644 --- a/src/options.c +++ b/src/options.c @@ -812,6 +812,19 @@ static void feh_parse_option_array(int argc, char **argv, int finalrun) add_file_to_filelist_recursively(argv[optind++], FILELIST_FIRST); } } + else if (finalrun && !opt.filelistfile && !opt.bgmode) { + if (opt.start_list_at && !path_is_url(opt.start_list_at) && strrchr(opt.start_list_at, '/')) { + char *target_directory = estrdup(opt.start_list_at); + char *filename_start = strrchr(target_directory, '/'); + if (filename_start) { + *filename_start = '\0'; + } + add_file_to_filelist_recursively(target_directory, FILELIST_FIRST); + free(target_directory); + } else { + add_file_to_filelist_recursively(".", FILELIST_FIRST); + } + } else if (finalrun && !opt.filelistfile && !opt.bgmode) add_file_to_filelist_recursively(".", FILELIST_FIRST); -- cgit v1.2.3 From 6ce29720a12026ca516a0314226353121d3e1b14 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 21 Nov 2018 19:40:05 +0100 Subject: Release v3.1 --- ChangeLog | 3 ++- man/feh.pre | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'man') diff --git a/ChangeLog b/ChangeLog index 58a0e90..01ec97d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,6 @@ -git HEAD +Wed, 21 Nov 2018 19:37:34 +0100 Daniel Friesel +* Release v3.1 * Running "feh --start-at .../file.jpg" without specifying images, directories or filelists to load is now equivalent to running "feh --start-at .../file.jpg $(dirname .../file.jpg)". This way, it is diff --git a/man/feh.pre b/man/feh.pre index d5d7cbf..da5e890 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -730,7 +730,7 @@ to sort numbers naturally, so that e.g. 10.jpg comes after 2.jpg. . Start the filelist at .Ar filename . -If no files or filelists were specifed on the commandline, +If no other files or filelists were specifed on the commandline, .Nm will first load all files from the directory in which .Ar filename -- cgit v1.2.3 From 3df7651f58a199ffddd7e1210eea79a26a05a68a Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Fri, 7 Dec 2018 22:49:46 +0100 Subject: feh(1): key/mouse actions are not handled when loading via libcurl --- man/feh.pre | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index da5e890..dd3d658 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1972,7 +1972,7 @@ must be compiled with libcurl support. It is $MAN_CURL$ in this build . . -.Sh BUGS +.Sh KNOWN BUGS . On systems with giflib 5.1.2, .Nm @@ -1992,6 +1992,12 @@ upgrade to giflib 5.1.4. . .Pp . +While loading images using libcurl, +.Nm +will not react to key or mouse actions. +. +.Pp +. Thumbnail mode is somewhat inefficient, and because of that not nearly as fast as it could be. . -- cgit v1.2.3 From c2efc3491979a9fadcc32496c319ebefcb2a8301 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 23 Dec 2018 16:19:54 +0100 Subject: feh(1): Document maximum line length and splitting details in themes file --- man/feh.pre | 3 +++ 1 file changed, 3 insertions(+) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index dd3d658..ea47582 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1318,6 +1318,9 @@ to use these options. . Note that you can split a theme over several lines by placing a backslash at the end of an unfinished line. +A single option-argument-pair must not span multiple lines. +A single line must not be longer than 1023 characters, but there's no upper +limit for the length of a theme. . .Pp . -- cgit v1.2.3 From fb4aceb047a4bcd3c64e0b0c4de64890cef0dc69 Mon Sep 17 00:00:00 2001 From: guraga Date: Mon, 21 Jan 2019 15:24:29 +0700 Subject: Update "man/feh.pre" Small fixes in man page. --- man/feh.pre | 52 ++++++++++++++++++++++++++++------------------------ 1 file changed, 28 insertions(+), 24 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index ea47582..bbf58d0 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -129,21 +129,21 @@ This is useful for preening a directory. .Sh SUPPORTED FORMATS . .Nm -can open any format supported by Imlib2, most notably jpeg, png, +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. . If the convert binary .Pq supplied by ImageMagick -is available, it also has limited support for many other filetypes, such as +is available, it also has limited support for many other file types, 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 --conversion-timeout Ar num +.Cm --conversion-timeout Ar timeout with a non-negative value to enable support for these formats. . . @@ -224,7 +224,7 @@ Create borderless windows. . .It Cm --cache-size Ar size . -Set Imlib2 in-memory cache to +Set imlib2 in-memory cache to .Ar size MiB. A higher cache size can significantly improve performance especially for small @@ -259,7 +259,7 @@ the caption will be looked for in .It Cm --conversion-timeout Ar timeout . .Nm -can use ImageMagick to try converting unloadable files into a supportad +can use ImageMagick to try converting unloadable files into a supported file format. As this can take a long time, it is disabled by default. Set @@ -293,7 +293,7 @@ with exiv2 / exifgrep . . .It Cm -d , --draw-filename . -Draw the filename at the top-left of the image. +Draw the file name at the top-left of the image. . .It Cm --draw-tinted . @@ -313,8 +313,8 @@ 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 -directory, one filename per line. +The format is a list of image file names, absolute or relative to the current +directory, one file name per line. . .Pp . @@ -363,7 +363,7 @@ add multiple paths. . .It Cm --force-aliasing . -Disable antialiasing for zooming, background setting etc. +Disable anti-aliasing for zooming, background setting etc. . .It Cm -I , --fullindex . @@ -428,7 +428,7 @@ 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 . +.Pq e.g. 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 . @@ -447,10 +447,10 @@ Index mode enables certain other options, see and .Sx MONTAGE MODE OPTIONS . . -.It Cm --info Oo Ar flag Oc Ns Ar commandline +.It Cm --info Oo Ar flag Oc Ns Ar command_line . Execute -.Ar commandline +.Ar command_line 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 @@ -627,7 +627,7 @@ from last to first image). . .It Cm -r , --recursive . -Recursively expand any directories in the commandline arguments +Recursively expand any directories in the command line arguments to the content of those directories, all the way down to the bottom level. . .It Cm --no-recursive @@ -699,15 +699,19 @@ in paused mode. .It Cm -S , --sort Ar sort_type . Sort file list 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 is +Allowed sort types are: +.Cm name , filename , dirname , mtime , width , height , pixels , size , format . +For sort modes other than +.Cm name , filename , dirname , +or +.Cm mtime , +a preload run is necessary, causing a delay proportional to the number of images in the list. . .Pp . .Cm mtime -starts with the most recently modified image, +starts with the most recently modified image. .Cm width , height , pixels and .Cm size @@ -721,7 +725,7 @@ to sort by oldest or largest first. For .Cm name , filename , and -.Cm dirname , +.Cm dirname you can use .Cm --version-sort to sort numbers naturally, so that e.g. 10.jpg comes after 2.jpg. @@ -730,7 +734,7 @@ to sort numbers naturally, so that e.g. 10.jpg comes after 2.jpg. . Start the filelist at .Ar filename . -If no other files or filelists were specifed on the commandline, +If no other files or filelists were specified on the command line, .Nm will first load all files from the directory in which .Ar filename @@ -762,7 +766,7 @@ Load options from config file with name - see .Sx THEMES CONFIG SYNTAX for more info. -Note that commandline options always override theme options. +Note that command line options always override theme options. The theme can also be set via the program name .Pq e.g. with symlinks , so by default @@ -1640,7 +1644,7 @@ Scroll up . Scroll down. Note that the scroll keys work without anti-aliasing for performance reasons; -hit the render key after scrolling to antialias the image. +hit the render key after scrolling to anti-alias the image. . .It Aq Alt+Left Bq scroll_left_page . @@ -1660,7 +1664,7 @@ Scroll down by one page . .It R, Ao keypad begin Ac Bq render . -Antialias the image. +Anti-alias the image. Opens the currently selected image in thumbnail mode. . .It Ao keypad + Ac , Ao Up Ac Bq zoom_in @@ -1969,7 +1973,7 @@ for lossless JPEG rotation. . .Pp . -To view images from URLs such as http://, +To view images from URLs such as "http://", .Nm must be compiled with libcurl support. It is $MAN_CURL$ in this build @@ -2015,7 +2019,7 @@ window slightly too large. If you find a bug, please report it to .Aq derf+feh@finalrewind.org or via -.Aq http://github.com/derf/feh/issues . +.Aq https://github.com/derf/feh/issues . You are also welcome to direct any feh-related comments/questions/... to #feh on irc.oftc.net. . -- cgit v1.2.3 From bbf0d721516cbbd561ef2b4fd698e1ebf722cdd9 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sat, 16 Feb 2019 17:45:37 +0100 Subject: feh(1): Add example for showing only landscape-mode pictures --- man/feh.pre | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index bbf58d0..913b9b3 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1954,6 +1954,12 @@ Show some EXIF information, extracted by exifprobe/exifgrep Recursively remove all images with dimensions below or equal to 1000x800 pixels from the current directory. . +.It feh -L '%w %h %f' \&| awk '{ if \&($1 > $2\&) { print $0 } }' \&| cut -d ' ' -f 3- \&| feh -f - +. +Show landscape pictures +.Pq image width greater than height +in the current directory. +. .El . . -- cgit v1.2.3 From 18dd1c5ea218c1b86e305d3ee0052335b1e22fc8 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Tue, 26 Mar 2019 17:19:39 +0100 Subject: Make SIGUSR1 / SIGUSR2 relaod the current image in single-file slideshows --- man/feh.pre | 10 +++++++--- src/signals.c | 13 +++++++++---- 2 files changed, 16 insertions(+), 7 deletions(-) (limited to 'man') diff --git a/man/feh.pre b/man/feh.pre index 913b9b3..b1ef16a 100644 --- a/man/feh.pre +++ b/man/feh.pre @@ -1856,7 +1856,7 @@ So, to enlarge a specific part of an image, click the zoom button on that part. . .Sh SIGNALS . -In slideshow mode, +In slideshow and multiwindow mode, .Nm handles the following signals: . @@ -1864,11 +1864,15 @@ handles the following signals: . .It Dv SIGUSR1 . -Switch to next image +Slideshow mode: switch to next image; +reload current image if the slideshow consists of a single file. +Multiwindow mode: reload all images. . .It Dv SIGUSR2 . -Switch to previous image +Slideshow mode: switch to previous image; +reload current image if the slideshow consists of a single file. +Multiwindow mode: reload all images. . .El . diff --git a/src/signals.c b/src/signals.c index d65f49b..85d81bc 100644 --- a/src/signals.c +++ b/src/signals.c @@ -24,6 +24,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ #include "feh.h" +#include "filelist.h" #include "winwidget.h" #include "options.h" @@ -94,10 +95,14 @@ void feh_handle_signal(int signo) winwid = winwidget_get_first_window_of_type(WIN_TYPE_SLIDESHOW); if (winwid) { - if (signo == SIGUSR1) - slideshow_change_image(winwid, SLIDE_NEXT, 1); - else if (signo == SIGUSR2) - slideshow_change_image(winwid, SLIDE_PREV, 1); + if (filelist_len > 1) { + if (signo == SIGUSR1) + slideshow_change_image(winwid, SLIDE_NEXT, 1); + else if (signo == SIGUSR2) + slideshow_change_image(winwid, SLIDE_PREV, 1); + } else { + feh_reload_image(winwid, 0, 0); + } } else if (opt.multiwindow) { for (i = window_num - 1; i >= 0; i--) feh_reload_image(windows[i], 0, 0); -- cgit v1.2.3