change arg, old arg is still recognized

This commit is contained in:
speedie 2023-04-22 14:18:30 +02:00
parent 9347780cac
commit de3264d4f6
7 changed files with 5 additions and 5 deletions

Binary file not shown.

BIN
code.pdf

Binary file not shown.

View file

@ -32,7 +32,7 @@ Arguments
You may use long, descriptive arguments or the shorter arguments.
`-mh, --lineheight height`
`-mh, --line-height height`
: Set spmenu line height to height
`-mw, --min-width width`

View file

@ -207,7 +207,7 @@ readargs(int argc, char *argv[])
maxcache = atoi(argv[++i]);
} else if (!strcmp(argv[i], "-l") || (!strcmp(argv[i], "--lines"))) { // number of lines in grid
lines = atoi(argv[++i]);
} else if (!strcmp(argv[i], "-mh") || (!strcmp(argv[i], "--lineheight"))) { // line height
} else if (!strcmp(argv[i], "-mh") || (!strcmp(argv[i], "--lineheight")) || (!strcmp(argv[i], "--line-height"))) { // line height
lineheight += atoi(argv[++i]);
if (columns == 0) columns = 1;
} else if (!strcmp(argv[i], "-mw") || (!strcmp(argv[i], "--min-width"))) { // line height
@ -415,7 +415,7 @@ usage(void)
fputs("spmenu: fancy dynamic menu\n\n"
"- Arguments -\n"
"spmenu -l, --lines <line> Set line count to stdin\n"
"spmenu -mh, --lineheight <height> Set spmenu line height to <height>\n"
"spmenu -mh, --line-height <height> Set spmenu line height to <height>\n"
"spmenu -mw, --min-width <width> Set minimum width to <width>\n"
"spmenu -g, --columns <grid> Set the number of grids to <grid>\n"
"spmenu -gc, --generate-cache Generate image cache\n"

View file

@ -49,7 +49,7 @@ See a list below for a list.
.PP
You may use long, descriptive arguments or the shorter arguments.
.TP
\f[V]-mh, --lineheight height\f[R]
\f[V]-mh, --line-height height\f[R]
Set spmenu line height to height
.TP
\f[V]-mw, --min-width width\f[R]

View file

@ -191,7 +191,7 @@ spmenu. See a list below for a list.</p>
<h1 id="arguments">Arguments</h1>
<p>You may use long, descriptive arguments or the shorter arguments.</p>
<dl>
<dt><code>-mh, --lineheight height</code></dt>
<dt><code>-mh, --line-height height</code></dt>
<dd>
Set spmenu line height to height
</dd>

Binary file not shown.