diff options
author | NRK <nrk@disroot.org> | 2022-08-16 10:43:50 +0200 |
---|---|---|
committer | NRK <nrk@disroot.org> | 2022-08-16 10:43:50 +0200 |
commit | 216f312578be5c959527c03ccc70d27eebcc76aa (patch) | |
tree | 0dac281db909a1d27cc248c63f3c939f2632863d /etc/nsxiv.1 | |
parent | d9f20a41224265573395381fbbdea40ac9891d84 (diff) | |
download | nsxiv-216f312578be5c959527c03ccc70d27eebcc76aa.tar.zst |
add support for long-opts (#332)
Uses [optparse] to add support for long-opts. optparse is posix
compliant with getopt(3) and thus would be backwards compatible.
It does not have any dependency (not even the c standard library!) and
is C89 compatible and thus fits our current code-style.
[optparse]: https://github.com/skeeto/optparse
Note that we're using a couple `pragma`-s to silence some harmless
warnings. This should be portable because these pragma-s don't change the
behavior of the program. Furthermore, C standard mandates that unknown
pragma's should be ignored by the compiler and thus would not result in
build failure on compilers which do not recognize them.
Closes: https://codeberg.org/nsxiv/nsxiv/issues/328
Reviewed-on: https://codeberg.org/nsxiv/nsxiv/pulls/332
Reviewed-by: eylles <eylles@noreply.codeberg.org>
Diffstat (limited to 'etc/nsxiv.1')
-rw-r--r-- | etc/nsxiv.1 | 56 |
1 files changed, 28 insertions, 28 deletions
diff --git a/etc/nsxiv.1 b/etc/nsxiv.1 index f4801b0..29f036f 100644 --- a/etc/nsxiv.1 +++ b/etc/nsxiv.1 @@ -34,84 +34,84 @@ Please note, that the fullscreen mode requires an EWMH/NetWM-compliant window manager. .SH OPTIONS .TP -.BI "\-A " FRAMERATE +.BI "\-A, \-\-framerate " FRAMERATE Play animations with a constant frame rate set to .IR FRAMERATE . .TP -.B \-a +.B "\-a, \-\-animate" Play animations of multi-frame images. .TP -.B \-b +.B "\-b, \-\-no\-bar" Do not show statusbar at the bottom of the window. .TP -.B \-c +.B "\-c, \-\-clean\-cache" Remove all orphaned cache files from the thumbnail cache directory and exit. .TP -.BI "\-e " WID +.BI "\-e, \-\-embed " WID Embed nsxiv's window into window whose ID is .IR WID . .TP -.B \-f +.B "\-f, \-\-fullscreen" Start in fullscreen mode. .TP -.BI "\-G " GAMMA +.BI "\-G, \-\-gamma " GAMMA Set image gamma to GAMMA (\-32..32). .TP -.BI "\-g " GEOMETRY +.BI "\-g, \-\-geometry " GEOMETRY Set window position and size. See section GEOMETRY SPECIFICATIONS of X(7) for more information on GEOMETRY argument. .TP -.BI "\-N " NAME -Set the resource name of nsxiv's X window to NAME. -.TP -.BI "\-n " NUM -Start at picture number NUM. -.TP -.B \-h +.B "\-h, \-\-help" Print brief usage information to standard output and exit. .TP -.B \-i +.B "\-i, \-\-stdin" Read names of files to open from standard input. Also done if FILE is `-'. .TP -.B \-o +.BI "\-N, \-\-class " NAME +Set the resource name (WM_CLASS) of nsxiv's X window to NAME. +.TP +.BI "\-n, \-\-start\-at " NUM +Start at picture number NUM. +.TP +.B "\-o, \-\-stdout" Write list of all marked files to standard output when quitting. In combination with -.B \-i +.B "\-i, \-\-stdin" nsxiv can be used as a visual filter/pipe. .TP -.B \-p +.B "\-p, \-\-private" Enable private mode, in which nsxiv does not write any cache or temporary files. .TP -.B \-q +.B "\-q, \-\-quiet" Be quiet, and disable warnings to standard error stream. .TP -.B \-r +.B "\-r, \-\-recursive" Search the given directories recursively for images to view. .TP -.BI "\-S " DELAY +.BI "\-S, \-\-ss\-delay " DELAY Start in slideshow mode. Set the delay between images to .I DELAY seconds. .I DELAY may be a floating-point number. .TP -.BI "\-s " MODE +.BI "\-s, \-\-scale\-mode " MODE Set scale mode according to MODE character. Supported modes are: [d]own, [f]it, [F]ill, [w]idth, [h]eight. .TP -.B \-t +.B "\-t, \-\-thumbnail" Start in thumbnail mode. .TP -.B \-v +.B "\-v, \-\-version" Print version information to standard output and exit. .TP -.B \-Z +.B "\-Z, \-\-zoom\-100" The same as `\-z 100'. .TP -.BI "\-z " ZOOM +.BI "\-z, \-\-zoom " ZOOM Set zoom level to ZOOM percent. .TP -.B \-0 +.B "\-0, \-\-null" Use NULL-separator. With this option, output of \-o and file-list sent to the key-handler and the input of \-i will be separated by a NULL character. .SH KEYBOARD COMMANDS |