add documentation regarding emoji highlighting

This commit is contained in:
speedie 2023-04-02 17:52:15 +02:00
parent 485ad9fb58
commit 5abd434aa2
2 changed files with 18 additions and 3 deletions

View file

@ -482,6 +482,10 @@ that you might already be using in your shell scripts. This means you can
pipe practically any colored shell script straight into spmenu, pipe practically any colored shell script straight into spmenu,
no need to filter the output or anything. no need to filter the output or anything.
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.
Example: `printf "\033[0;44m😀\033[0mEmoji 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.
@ -501,6 +505,8 @@ Reset: `0`
NOTE: `;` is a separator, and in this example it separates the NOTE: `;` is a separator, and in this example it separates the
color number and normal/bright. \033 may also be written as `^]` or simply `ESC`. color number and normal/bright. \033 may also be written as `^]` or simply `ESC`.
The separator may be omitted for some sequences, such as `\033[0m` which
resets the colorscheme.
spmenu supports most color sequences, although not true color by default spmenu supports most color sequences, although not true color by default
(unless -sgr arguments are used). (unless -sgr arguments are used).
@ -508,9 +514,9 @@ spmenu supports most color sequences, although not true color by default
There are a few arguments, you can override SGR colors on-the-fly There are a few arguments, you can override SGR colors on-the-fly
using the `-sgrX` arguments. See 'Arguments' for more information. using the `-sgrX` arguments. See 'Arguments' for more information.
Just as a tip, you can pipe your colored spmenu output Just as a tip, you can pipe your colored spmenu output to
to `sed -e 's/\x1b\[[0-9;]*m//g'`. This will clear the SGR sequences from the output. `sed -e 's/\x1b\[[0-9;]*m//g'`. This will clear the SGR sequences from
This is useful when you want to check what the output actually is. the output. This is useful when you want to check what the output actually is.
Pango markup Pango markup
============ ============

View file

@ -508,6 +508,13 @@ scripts.
This means you can pipe practically any colored shell script straight This means you can pipe practically any colored shell script straight
into spmenu, no need to filter the output or anything. into spmenu, no need to filter the output or anything.
.PP .PP
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.
Example:
\f[V]printf \[dq]\[rs]033[0;44m😀\[rs]033[0mEmoji highlighting\[rs]n\[dq] | spmenu --columns 1\f[R]
.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.
.PP .PP
@ -527,6 +534,8 @@ NOTE: \f[V];\f[R] is a separator, and in this example it separates the
color number and normal/bright. color number and normal/bright.
\[rs]033 may also be written as \f[V]\[ha]]\f[R] or simply \[rs]033 may also be written as \f[V]\[ha]]\f[R] or simply
\f[V]ESC\f[R]. \f[V]ESC\f[R].
The separator may be omitted for some sequences, such as
\f[V]\[rs]033[0m\f[R] which resets the colorscheme.
.PP .PP
spmenu supports most color sequences, although not true color by default spmenu supports most color sequences, although not true color by default
(unless -sgr arguments are used). (unless -sgr arguments are used).