[Konsole-devel] Patch for konsole
Éric Brunet
ebrunet at lps.ens.fr
Wed Jun 26 13:58:58 UTC 2002
Hello all,
I propose to remove the line 888 from kdebase/konsole/konsole/TEmuVt102.cpp
It is in the method void TEmuVt102::onKeyPress( QKeyEvent* ev ) which
decides what to do during a key press in konsole. Deep inside the
function, we have the following code:
887 if (cmd==CMD_send) {
888 if (ev->state() & AltButton) sendString("\033");
889 emit sndBlock(txt,len);
890 return;
891 }
(Note: I am using the version under the HEAD label at http://lxr.kde.org/source/)
Translation:
887 if the user **explicitely** specified some text to send for the key
event being processed {
888 if this event includes the Alt modifier, first send <Escape>
889 now send what the user **explicitely** said he wanted to send
890 we're done.
891 }
In other words, if the user writes in his config .keytab file:
key H +Alt : "Hello, world !"
then, when he presses alt-h, konsole will send
<Escape>Hello, world !
Of course, this is quite a weird behaviour; if the user really wanted the
extra <Escape>, he could have written in his .keytab file:
key H +Alt : "\eHello, world !"
If he doesn't want the <Escape> character, konsole is unusable for his purpose.
Note that the source code quoted above is used only when the user specifies
something in his .keytab. If he doesn't specify anything in his config
file, another part of the code will add the <Escape> prefix, and emacs
users will still be happy.
So, what do you think ? Could someone with a CVS write access remove the
offending line, or did I miss something ? Or maybe I should fill a bug
report ?
Éric Brunet
More information about the konsole-devel
mailing list