<feed xmlns='http://www.w3.org/2005/Atom'>
<title>nsxiv/options.c, branch master</title>
<subtitle>Nsxiv image view custom build
</subtitle>
<id>https://git.krolyxon.com/nsxiv/atom?h=master</id>
<link rel='self' href='https://git.krolyxon.com/nsxiv/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/'/>
<updated>2023-03-11T12:37:04Z</updated>
<entry>
<title>apply clang-format</title>
<updated>2023-03-11T12:37:04Z</updated>
<author>
<name>NRK</name>
<email>nrk@disroot.org</email>
</author>
<published>2023-02-10T05:35:53Z</published>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/commit/?id=f2f4903de4bd3ce06c03dd66f0c9a7dda97a3550'/>
<id>urn:sha1:f2f4903de4bd3ce06c03dd66f0c9a7dda97a3550</id>
<content type='text'>
minus the bogus changes

Co-authored-by: Berke Kocaoğlu &lt;berke.kocaoglu@metu.edu.tr&gt;
</content>
</entry>
<entry>
<title>remove deprecated -T flag</title>
<updated>2023-01-28T10:29:36Z</updated>
<author>
<name>NRK</name>
<email>nrk@disroot.org</email>
</author>
<published>2023-01-15T09:27:13Z</published>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/commit/?id=cc9b24f36bc2cabb6c16bce5f4ae8853799ccc6a'/>
<id>urn:sha1:cc9b24f36bc2cabb6c16bce5f4ae8853799ccc6a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>update copyright year</title>
<updated>2023-01-28T10:29:36Z</updated>
<author>
<name>NRK</name>
<email>nrk@disroot.org</email>
</author>
<published>2023-01-15T09:26:46Z</published>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/commit/?id=a051ad210dc0571ec581c89171dc25b9ab35f4be'/>
<id>urn:sha1:a051ad210dc0571ec581c89171dc25b9ab35f4be</id>
<content type='text'>
</content>
</entry>
<entry>
<title>add cli flag --alpha-layer</title>
<updated>2023-01-28T10:23:11Z</updated>
<author>
<name>NRK</name>
<email>nrk@disroot.org</email>
</author>
<published>2023-01-17T09:48:59Z</published>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/commit/?id=1f788a318bedc0e6a83632c1f126e747c0430d6c'/>
<id>urn:sha1:1f788a318bedc0e6a83632c1f126e747c0430d6c</id>
<content type='text'>
now that we have long-opts, we don't have to worry about exhausting the
alphabet list for short-opts. so adding a cli flag to set/unset the
checker background makes sense.

ref: https://codeberg.org/nsxiv/nsxiv/issues/404
</content>
</entry>
<entry>
<title>improve error message on bad cli argument (#371)</title>
<updated>2022-09-28T16:15:09Z</updated>
<author>
<name>NRK</name>
<email>nrk@disroot.org</email>
</author>
<published>2022-09-28T16:15:09Z</published>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/commit/?id=85fffbb277418dfc5e03fc8e01335553333d8049'/>
<id>urn:sha1:85fffbb277418dfc5e03fc8e01335553333d8049</id>
<content type='text'>
currently the error messages have the shortopt hardcoded in them, even
when the user actually entered a longopt:

	$ ./nsxiv --framerate v
	nsxiv: Invalid argument for option -A: v

and as far as I see, there's no way to *reliably* tell weather we're
processing a longopt or a shortopt. perhaps we can do some shenanigangs
with `optind` but that seems finicky at best.

and it seems like other coreutils which support longopt has similar issues:

	$ xargs --max-procs=z
	xargs: invalid number "z" for -P option

utils like `grep` and `head` seems to work-around it by not mentioning the flag:

	$ head --lines=z
	head: invalid number of lines: ‘z’
	$ grep --max-count=l
	grep: invalid max count

this patch does the same thing as `grep/head` and omits the flag from
the error message.

Closes: https://codeberg.org/nsxiv/nsxiv/issues/368

Reviewed-on: https://codeberg.org/nsxiv/nsxiv/pulls/371
Reviewed-by: Berke Kocaoğlu &lt;berke.kocaoglu@metu.edu.tr&gt;
</content>
</entry>
<entry>
<title>fix potential truncation of cli arguments (#367)</title>
<updated>2022-09-14T04:58:41Z</updated>
<author>
<name>NRK</name>
<email>nrk@disroot.org</email>
</author>
<published>2022-09-14T04:58:41Z</published>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/commit/?id=daee34477a87f7eb97aa537577a48ddcf5a7d30b'/>
<id>urn:sha1:daee34477a87f7eb97aa537577a48ddcf5a7d30b</id>
<content type='text'>
strtol() returns a `long`, but we're storing the result in an `int`
which might end up getting truncated. change `n` to `long` and guard
against &gt;INT_MAX arguments in cases where it matters.

use a float for storing argument of `-S`

change `opt.slideshow` to `unsigned` similar to `img.ss.delay`

Co-authored-by: Berke Kocaoğlu &lt;berke.kocaoglu@metu.edu.tr&gt;
Reviewed-on: https://codeberg.org/nsxiv/nsxiv/pulls/367
Reviewed-by: Berke Kocaoğlu &lt;berke.kocaoglu@metu.edu.tr&gt;
Reviewed-by: explosion-mental &lt;explosion-mental@noreply.codeberg.org&gt;
</content>
</entry>
<entry>
<title>rename: aa -&gt; anti_alias</title>
<updated>2022-09-10T13:43:14Z</updated>
<author>
<name>NRK</name>
<email>nrk@disroot.org</email>
</author>
<published>2022-09-10T13:30:40Z</published>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/commit/?id=e356add07c6246b8a27a5d193e2e89da4afee6ad'/>
<id>urn:sha1:e356add07c6246b8a27a5d193e2e89da4afee6ad</id>
<content type='text'>
</content>
</entry>
<entry>
<title>allow disabling anti-aliasing via cli flag</title>
<updated>2022-09-10T13:43:07Z</updated>
<author>
<name>NRK</name>
<email>nrk@disroot.org</email>
</author>
<published>2022-08-17T14:54:14Z</published>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/commit/?id=88a480c9388d698f123bf892f33197d7bd1cfb9b'/>
<id>urn:sha1:88a480c9388d698f123bf892f33197d7bd1cfb9b</id>
<content type='text'>
simply running nsxiv with `--anti-alias` will enable anti-aliasing, and
running it with `--anti-alias=no` will disable it.

the cli flag will overwrite the config.h default.

Closes: https://codeberg.org/nsxiv/nsxiv/issues/349
</content>
</entry>
<entry>
<title>remove some hardcoded "nsxiv", use progname instead</title>
<updated>2022-09-05T01:52:51Z</updated>
<author>
<name>NRK</name>
<email>nrk@disroot.org</email>
</author>
<published>2022-07-15T05:56:45Z</published>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/commit/?id=7e3e6008fec8f7de8fa3c3545a76d5380ba48944'/>
<id>urn:sha1:7e3e6008fec8f7de8fa3c3545a76d5380ba48944</id>
<content type='text'>
</content>
</entry>
<entry>
<title>don't assume positive argc</title>
<updated>2022-09-05T01:52:51Z</updated>
<author>
<name>NRK</name>
<email>nrk@disroot.org</email>
</author>
<published>2022-06-16T13:33:32Z</published>
<link rel='alternate' type='text/html' href='https://git.krolyxon.com/nsxiv/commit/?id=fbe186e79d2083a7bbd1588b317cd5782bc5ae73'/>
<id>urn:sha1:fbe186e79d2083a7bbd1588b317cd5782bc5ae73</id>
<content type='text'>
handle a rare, but possible case of argc being 0, in which case argv[0]
would be null.

note that both POSIX and ISO C standard allow argc to be 0 and in
practice this can be triggered via calling `exec(3)` family of functions
with NULL as the first `argv`.
</content>
</entry>
</feed>
