How to forward `` Ctrl> - <Tab> '' to Konsole?
I want to use smart tabs in Emacs in C ++ mode, but I also want to be able to insert a tab character when necessary. From other posts, I understand that the easiest way is to snap <Ctrl>-<Tab>to indentation. However, it looks like Konsole will not send to KUbuntu <Ctrl>?
My current .emacs file contains:
(defun my-c-mode-common-hook ()
(setq c++-tab-always-indent t)
(setq tab-width 4)
(setq indent-tabs-mode t)
)
(add-hook 'c-mode-common-hook 'my-c-mode-common-hook)
(global-set-key [C-tab] 'self-insert-command)
Therefore, I believe that this will lead to binding <Ctrl>-<Tab>to the insertion of a tab character. However, when I run:
<Ctrl>-h k <Ctrl>-<Tab>
Emacs , . - Konsole ( ) KUbuntu, , <Ctrl>- ? (, , <Ctrl>-blah.)
+3
2
:
- . ~/.kde///Konsole/Linux-custom.keytab
, keytab
% konsole --keytab linux-custom
Emacs
linux-custom.keytab
key Tab +Control : "\E[4t" # control tab will generate esc [ 4 t
key Backtab : "\E[4s" # shift tab will generate esc [ 4 s
( key code, , .)
Emacs, .emacs,
(define-prefix-command 'terminal-key-map)
(global-set-key (kbd "\e[") 'terminal-key-map)
(define-key terminal-key-map (kbd "4t") 'other-window) ;control tab
(define-key terminal-key-map (kbd "4s") 'other-window) ;shift tab
, control ;, control ', control = .. .
+2