Discussion:
[dev] [st] shift + backspace
r***@gmail.com
2018-04-28 18:19:16 UTC
Permalink
When using a program without readline inside st, shift + backspace
becomes ^H. Same thing if caps-lock is activated.
This is very annoying. Other terminals don't do that.
Could this be fixed in future releases?
Quentin Rameau
2018-04-28 20:24:38 UTC
Permalink
> When using a program without readline inside st, shift + backspace
> becomes ^H. Same thing if caps-lock is activated.
> This is very annoying. Other terminals don't do that.
> Could this be fixed in future releases?

Where is the patch?
Roberto E. Vargas Caballero
2018-04-29 15:50:25 UTC
Permalink
,p
Daniel Tameling
2018-05-05 17:53:34 UTC
Permalink
On Sat, Apr 28, 2018 at 08:19:16PM +0200, ***@gmail.com wrote:
> When using a program without readline inside st, shift + backspace
> becomes ^H. Same thing if caps-lock is activated.
> This is very annoying. Other terminals don't do that.
> Could this be fixed in future releases?
>

Hi,

the following patch should give you the behavior you want.

Best regards,
Daniel

---
config.def.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/config.def.h b/config.def.h
index 82b1b09..1a0dfbf 100644
--- a/config.def.h
+++ b/config.def.h
@@ -336,8 +336,8 @@ static Key key[] = {
{ XK_Delete, ShiftMask, "\033[3;2~", +1, 0},
{ XK_Delete, XK_ANY_MOD, "\033[P", -1, 0},
{ XK_Delete, XK_ANY_MOD, "\033[3~", +1, 0},
- { XK_BackSpace, XK_NO_MOD, "\177", 0, 0},
{ XK_BackSpace, Mod1Mask, "\033\177", 0, 0},
+ { XK_BackSpace, XK_ANY_MOD, "\177", 0, 0},
{ XK_Home, ShiftMask, "\033[2J", 0, -1},
{ XK_Home, ShiftMask, "\033[1;2H", 0, +1},
{ XK_Home, XK_ANY_MOD, "\033[H", 0, -1},
--
2.15.1
r***@gmail.com
2018-05-05 18:20:01 UTC
Permalink
Daniel Tameling <***@gmail.com> wrote:

> On Sat, Apr 28, 2018 at 08:19:16PM +0200, ***@gmail.com wrote:
> > When using a program without readline inside st, shift + backspace
> > becomes ^H. Same thing if caps-lock is activated.
> > This is very annoying. Other terminals don't do that.
> > Could this be fixed in future releases?
> >
>
> Hi,
>
> the following patch should give you the behavior you want.
>
> Best regards,
> Daniel
>
> ---
> config.def.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/config.def.h b/config.def.h
> index 82b1b09..1a0dfbf 100644
> --- a/config.def.h
> +++ b/config.def.h
> @@ -336,8 +336,8 @@ static Key key[] = {
> { XK_Delete, ShiftMask, "\033[3;2~", +1, 0},
> { XK_Delete, XK_ANY_MOD, "\033[P", -1, 0},
> { XK_Delete, XK_ANY_MOD, "\033[3~", +1, 0},
> - { XK_BackSpace, XK_NO_MOD, "\177", 0, 0},
> { XK_BackSpace, Mod1Mask, "\033\177", 0, 0},
> + { XK_BackSpace, XK_ANY_MOD, "\177", 0, 0},
> { XK_Home, ShiftMask, "\033[2J", 0, -1},
> { XK_Home, ShiftMask, "\033[1;2H", 0, +1},
> { XK_Home, XK_ANY_MOD, "\033[H", 0, -1},
> --
> 2.15.1

It works. Thank you.
Continue reading on narkive:
Loading...