[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
I don't understand ncurses dealing with control-ARROW
From: |
Steffen Nurpmeso |
Subject: |
I don't understand ncurses dealing with control-ARROW |
Date: |
Thu, 17 Dec 2015 22:52:38 +0100 |
User-agent: |
s-nail v14.8.5-206-gfc8f312-dirty |
Hello,
this is not really a bug ... most likely that is. It is the only
list regarding ncurses, and so .. and maybe it is. Well.
I'm currently rewriting some code that deals with termcap (being
out of the question before) and don't actually understand how to
get at the control-ARROW etc. modifiers.
Now let aside that i don't understand why the real terminal that
is on right now generates ^[[5D (via "$ cat" and in the "Keyboard"
setting) but tigetstr(3) gives me "0x1B(x5B([) 0x31(1) 0x3B(;)
0x35(5) 0x44(D)" -- even though that is the correct return for
nsterm, yet TERM=screen.xterm-256color (over ssh) and infocmp(1)
doesn't output anything for kLFT5. How do you do that? ..Is this
interpolated given that kLFT=\E[1;2D for both? (..Likely..)
My question is why this is kLFT5 given that Caps.keys says the
capname will be kclft? Also, for kclft there is a %k termcap
mapping, but i couldn't find any hint on such a thing for kLFT5.
For me the worst is that i cannot give end-users just any hint on
how to get at the actual name nor sequence, except by copy+pasting
a small C program that queries kLFT5++ and returns what is true as
opposed to what infocmp says for $TERM. I'm thinking about
deliberately violating ncurses (?) by using tigetstr() in
conjunction with tgetent() when it is available.
--steffen
- I don't understand ncurses dealing with control-ARROW,
Steffen Nurpmeso <=