forked from speedie/spmenu
finish the -It argument
This commit is contained in:
parent
4d1e640e89
commit
2c68937e38
|
@ -71,6 +71,9 @@ You may use long, descriptive arguments or the shorter arguments.
|
||||||
`-p, --prompt text`
|
`-p, --prompt text`
|
||||||
: Set spmenu prompt text to text
|
: Set spmenu prompt text to text
|
||||||
|
|
||||||
|
`-It, --input text`
|
||||||
|
: Set initial input text to text
|
||||||
|
|
||||||
`-ip, --indent`
|
`-ip, --indent`
|
||||||
: Indent items to prompt width
|
: Indent items to prompt width
|
||||||
|
|
||||||
|
@ -486,7 +489,7 @@ no need to filter the output or anything.
|
||||||
|
|
||||||
Not only does it support colored text, but it also supports colored backgrounds.
|
Not only does it support colored text, but it also supports colored backgrounds.
|
||||||
This allows something similar to the emoji highlight patch, except even more useful.
|
This allows something similar to the emoji highlight patch, except even more useful.
|
||||||
Example: `printf "\033[0;44m😀\033[0mEmoji highlighting\n" | spmenu --columns 1`
|
Example: `printf "\033[0;44m😀\033[0m Emoji highlighting\n" | spmenu --columns 1`
|
||||||
|
|
||||||
For 256 color support to work, you must add to the array. See `libs/color.h`
|
For 256 color support to work, you must add to the array. See `libs/color.h`
|
||||||
if you want this.
|
if you want this.
|
||||||
|
@ -645,7 +648,8 @@ In addition to the aforementioned `spmenu_run`, the spmenu package also provides
|
||||||
Unlike the regular run launcher though, spmenu_desktop supports displaying an
|
Unlike the regular run launcher though, spmenu_desktop supports displaying an
|
||||||
icon for entries that use one.
|
icon for entries that use one.
|
||||||
|
|
||||||
It can be configured through editing `~/.config/spmenu/desktop/config`.
|
It can be configured through editing `~/.config/spmenu/desktop/config`. The
|
||||||
|
configuration file can also be moved by setting `${XDG_CONFIG_HOME}`.
|
||||||
|
|
||||||
spmenu commands
|
spmenu commands
|
||||||
===============
|
===============
|
||||||
|
|
|
@ -214,6 +214,8 @@ readargs(int argc, char *argv[])
|
||||||
dmw = atoi(argv[++i]);
|
dmw = atoi(argv[++i]);
|
||||||
else if (!strcmp(argv[i], "-p") || (!strcmp(argv[i], "--prompt"))) // adds prompt to left of input field
|
else if (!strcmp(argv[i], "-p") || (!strcmp(argv[i], "--prompt"))) // adds prompt to left of input field
|
||||||
prompt = argv[++i];
|
prompt = argv[++i];
|
||||||
|
else if (!strcmp(argv[i], "-It") || (!strcmp(argv[i], "--input"))) // specify initial text
|
||||||
|
input = argv[++i];
|
||||||
else if (!strcmp(argv[i], "-fn") || (!strcmp(argv[i], "--font"))) // font or font set
|
else if (!strcmp(argv[i], "-fn") || (!strcmp(argv[i], "--font"))) // font or font set
|
||||||
fonts[0] = argv[++i];
|
fonts[0] = argv[++i];
|
||||||
else if (!strcmp(argv[i], "-nmt") || (!strcmp(argv[i], "--normal-mode-text"))) // normal mode text
|
else if (!strcmp(argv[i], "-nmt") || (!strcmp(argv[i], "--normal-mode-text"))) // normal mode text
|
||||||
|
@ -378,6 +380,7 @@ usage(void)
|
||||||
"spmenu -NF, --no-fuzzy Disable fuzzy matching\n"
|
"spmenu -NF, --no-fuzzy Disable fuzzy matching\n"
|
||||||
"spmenu -P, --password Hide characters\n"
|
"spmenu -P, --password Hide characters\n"
|
||||||
"spmenu -p, --prompt <text> Set spmenu prompt text to <text>\n"
|
"spmenu -p, --prompt <text> Set spmenu prompt text to <text>\n"
|
||||||
|
"spmenu -It, --input <text> Set initial input text to <text>\n"
|
||||||
"spmenu -ip, --indent Indent items to prompt width\n"
|
"spmenu -ip, --indent Indent items to prompt width\n"
|
||||||
"spmenu -nip, --no-indent Don't indent items to prompt width\n"
|
"spmenu -nip, --no-indent Don't indent items to prompt width\n"
|
||||||
"spmenu -ci, --color-items Color items\n"
|
"spmenu -ci, --color-items Color items\n"
|
||||||
|
|
7
spmenu.1
7
spmenu.1
|
@ -88,6 +88,9 @@ Hide characters
|
||||||
\f[V]-p, --prompt text\f[R]
|
\f[V]-p, --prompt text\f[R]
|
||||||
Set spmenu prompt text to text
|
Set spmenu prompt text to text
|
||||||
.TP
|
.TP
|
||||||
|
\f[V]-It, --input text\f[R]
|
||||||
|
Set initial input text to text
|
||||||
|
.TP
|
||||||
\f[V]-ip, --indent\f[R]
|
\f[V]-ip, --indent\f[R]
|
||||||
Indent items to prompt width
|
Indent items to prompt width
|
||||||
.TP
|
.TP
|
||||||
|
@ -513,7 +516,7 @@ backgrounds.
|
||||||
This allows something similar to the emoji highlight patch, except even
|
This allows something similar to the emoji highlight patch, except even
|
||||||
more useful.
|
more useful.
|
||||||
Example:
|
Example:
|
||||||
\f[V]printf \[dq]\[rs]033[0;44m😀\[rs]033[0mEmoji highlighting\[rs]n\[dq] | spmenu --columns 1\f[R]
|
\f[V]printf \[dq]\[rs]033[0;44m😀\[rs]033[0m Emoji highlighting\[rs]n\[dq] | spmenu --columns 1\f[R]
|
||||||
.PP
|
.PP
|
||||||
For 256 color support to work, you must add to the array.
|
For 256 color support to work, you must add to the array.
|
||||||
See \f[V]libs/color.h\f[R] if you want this.
|
See \f[V]libs/color.h\f[R] if you want this.
|
||||||
|
@ -689,6 +692,8 @@ displaying an icon for entries that use one.
|
||||||
.PP
|
.PP
|
||||||
It can be configured through editing
|
It can be configured through editing
|
||||||
\f[V]\[ti]/.config/spmenu/desktop/config\f[R].
|
\f[V]\[ti]/.config/spmenu/desktop/config\f[R].
|
||||||
|
The configuration file can also be moved by setting
|
||||||
|
\f[V]${XDG_CONFIG_HOME}\f[R].
|
||||||
.SH spmenu commands
|
.SH spmenu commands
|
||||||
.PP
|
.PP
|
||||||
spmenu has a few special commands.
|
spmenu has a few special commands.
|
||||||
|
|
Loading…
Reference in a new issue