delete button in console

mfv mfv at bway.net
Fri Jan 1 20:25:18 UTC 2016


> On Thu, 2015-12-31 at 20:27 Polytropon <freebsd at edvax.de> wrote:
>
>On Thu, 31 Dec 2015 14:11:53 -0500, mfv wrote:
>> Hello,
>> 
>> I have similar keybindings that operate as expected for both the
>> tty console and virtual console using xterm or urxvt.
>> 
>> However, the following keybindings (Ctrl+right_key_pad_arrow and
>> Crtrl+left_key_pad_arrow) do not work on the tty console:
>> 
>>     bindkey "\e[1;5C"   forward-word
>>     bindkey "\e[1;5D"   backward-word
>> 
>> Even though the environment variable for the terminal is identical:
>> 
>> # printenv | grep TERM
>> TERM=xterm  
>
>Or simply use "echo $TERM". :-)
>
>It even doesn't work with the traditional (sc-based) console
>where TERM=cons25l1 (or cons25 for US preference).
>
>Check the follwing in an X terminal:
>
>	% cat
>	^[[1;5D^[[1;5C	<- Ctrl + cursor keye
>	^[[D^[[C	<- cursor keys
>
>As expected, it works. And as you can see, it's the same code
>sequence you have assigned (Escape [ 1 ; 5 C and D).
>
>But when you do the same in text mode, both cases will (incorrectly)
>be the same:
>
>	% cat
>	^[[D^[[C	<- Ctrl + cursor keys
>	^[[D^[[C	<- cursor keys
>
>So the Control key combination isn't recognized properly.
>
>
>
>> Csh is my preferred shell for both console and virutal terminal.  
>
>So I'm not the last person actually using it... ;-)
>
>
>
>> Any suggestions for a key binding that works on the tty console
>> similar to the virtual terminal would be appreciated.
>> Alternatively, an explanation of why it will not work will also be
>> appreciated.  
>
>Sorry, no idea _why_ this is, but only _that_ it is.
>
>
>

Hello Polytropon,

Thanks for the clarification.  I've verified you key strokes on my host
and the results are identical.  I also tried a different console
driver, that is vt, and also different terminals from termcap (vt102)
and the result is the same.  Perhaps the cause is at a lower level.

Cheers ...

Marek


More information about the freebsd-questions mailing list