[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: A wish, a plea

From: Glyn Millington
Subject: Re: A wish, a plea
Date: Fri, 22 Jun 2007 09:41:12 +0100
User-agent: Gnus/5.110007 (No Gnus v0.7) Emacs/22.1 (gnu/linux)

address@hidden (Kim F. Storm) writes:

> Hacksaw <address@hidden> writes:
>> So I started writing, and I wrote for quite a while, it was really
>> flowing well, and I thought, hey, I should save, because I don't want
>> to lose this, but in my reverie, I hit the ^X^C first.
> Since both C-x and C-c are prefix keys, and thus used a lot in
> sequence with other keys, C-x C-c has always seemed like a
> particularly dangerous binding to me.
> One of the first things I changed when I started to use Emacs was
> to change the "kill-emacs" binding to C-x C-c C-x
> (global-set-key "\C-x\C-c"    'nil)
> (global-set-key "\C-x\C-c\C-x"        'save-buffers-kill-emacs)
> C-x C-c C-x works really well (it is still easy to type, and I've
> never hit it accidentally).

Another way round - pretty sure this isn't mine!!

;;; Don't quit unless you mean it!
  (defun maybe-save-buffers-kill-emacs (really)
      "If REALLY is 'yes', call save-buffers-kill-emacs."
      (interactive "sAre you sure about this? ")
      (if (equal really "yes")
    (global-set-key [(control x) (control c)] 'maybe-save-buffers-kill-emacs)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]