After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 599634 - CTRL-Home, CTRL-End simply sends Home and End to apps
CTRL-Home, CTRL-End simply sends Home and End to apps
Status: RESOLVED DUPLICATE of bug 600659
Product: vte
Classification: Core
Component: general
0.20.x
Other Linux
: Normal major
: ---
Assigned To: VTE Maintainers
VTE Maintainers
Depends on:
Blocks:
 
 
Reported: 2009-10-26 09:43 UTC by Peter Valdemar Mørch
Modified: 2010-04-10 04:04 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Peter Valdemar Mørch 2009-10-26 09:43:25 UTC
In "vim" and "emacs -nw" hitting CTRL-Home and CTRL-End sends the exact same bytes[1] as hitting Home and End respectively to apps. Therefore, CTRL-Home and CTRL-End don't work in neither vim nor "emacs -nw" under gnome-terminal. They work fine under xterm.

Using the short perl snippet below[2], gnome-terminal produces this same output hitting either Home or CTRL-Home:
 Decimal: 27    Hex: 1b
 Decimal: 79    Hex: 4f
 Decimal: 72    Hex: 48 

xterm produces this output when I hit CTRL-Home:
 Decimal: 27    Hex: 1b
 Decimal: 91    Hex: 5b
 Decimal: 49    Hex: 31
 Decimal: 59    Hex: 3b
 Decimal: 53    Hex: 35
 Decimal: 72    Hex: 48

But xterm produces this output when I hit "just" Home:
 Decimal: 27    Hex: 1b
 Decimal: 91    Hex: 5b
 Decimal: 72    Hex: 48

I don't know much about terminals, but I'm surprised that xterm and gnome-terminal send different things for just "Home". I'm also surprised that gnome-terminal sends the same things for both "Home" and "CTRL-Home". I expected gnome-terminal behavior to mimic xterm since TERM=xterm in both. But hey, I know so little about terminals, termcap etc.

I'm using a danish keyboard but have also tried reconfiguring to use a US keyboard. Same behavior.

Running up-to-date ubuntu jaunty with these versions:
vte: 1:0.20.0-0ubuntu2
gnome-terminal: 2.26.0-0ubuntu2.1

Looking through past bugs I found bug 375112 : "ctrl-key combinations yielding just key", but the patch in there was already applied in my vte version. So that isn't it. (The explanation doesn't quite fit either)

I took the liberty of choosing a "major" severity, since it seems to me that CTRL-Home and CTRL-End is broken.

[1] I'm not sure what the "things" are called: "chars", "bytes", "keycodes" - terminal terminology is confusing to me
[2]
#!/usr/bin/perl -w

use Term::ReadKey;
ReadMode('cbreak');
print "Press keys to see their ASCII values.  Use Ctrl-C to quit.\n";

while (1) {
    $char = ReadKey(0);
    last unless defined $char;
    printf(" Decimal: %d\tHex: %x\n", ord($char), ord($char));
}

ReadMode('normal');
Comment 1 Behdad Esfahbod 2009-10-26 19:50:59 UTC
Confirmed.
Comment 2 Yury V. Zaytsev 2010-04-09 20:45:05 UTC
It seems to me, that this bug is a duplicate of #600659 just as #612453:

https://bugzilla.gnome.org/show_bug.cgi?id=612453
https://bugzilla.gnome.org/show_bug.cgi?id=600659
Comment 3 Behdad Esfahbod 2010-04-10 04:04:34 UTC

*** This bug has been marked as a duplicate of bug 600659 ***