1行スクロール
(defun scroll-up-one-line () (interactive) (scroll-up 1)) (defun scroll-down-one-line () (interactive) (scroll-down 1)) (if (or (eq window-system 'x) (eq window-system 'w32) (eq window-system 'mac)) (progn (global-set-key [?\C--] 'scroll-down-one-line) (global-set-key [?\C-+] 'scroll-up-one-line) (global-set-key [?\C-=] 'scroll-up-one-line)) (progn (global-set-key [f17] 'scroll-down-one-line) (global-set-key [f18] 'scroll-up-one-line)))
XなフレームのEmacsのときはこれでOK。
ただ、ターミナルの中の-nwなEmacsだとC-+とかが効かないので、
mltermなら、~/.mlterm/keyに
Control+comma = "\x1b[25~" # F13 Control+period = "\x1b[26~" # F14 Control+minus = "\x1b[31~" # F17 Control+equal = "\x1b[32~" # F18 Control+Shift+plus = "\x1b[32~" # F18
ktermなら、
KTerm*VT100.Translations: #override \ Shift<Key>space: begin-conversion(JAPANESE_CONVERSION) \n\ !Ctrl<KeyPress>comma: string(0x1b) string("[25~") \n\ !Ctrl<KeyPress>period: string(0x1b) string("[26~") \n\ !Ctrl<KeyPress>minus: string(0x1b) string("[31~") \n\ !Ctrl<KeyPress>equal: string(0x1b) string("[32~") \n\ !Ctrl Shift <KeyPress>equal: string(0x1b) string("[32~")
としてるす。