Gnus development mailing list
 help / color / mirror / Atom feed
From: Kai.Grossjohann@CS.Uni-Dortmund.DE
Subject: Re: Editing (text/enriched) parts revisited
Date: 26 Apr 1999 17:14:34 +0200	[thread overview]
Message-ID: <vafogkbmn1h.fsf@ramses.cs.uni-dortmund.de> (raw)
In-Reply-To: =?iso-8859-1?q?Fran=E7ois?= Pinard's message of "26 Apr 1999 10:50:47 -0400"

François Pinard <pinard@iro.umontreal.ca> writes:

  > I got a slight problem, maybe some of you have a solution for it?
  > If I use `M-m p' followed by `M-x c-mode' to edit some C code
  > right in a message, the `C-c C-c' local keymap stops being
  > available to end editing that part, as `C-c C-c' means
  > `comment-region' in C mode.  I'm no big Emacs LISP expert, maybe
  > someone might explain me how I could override `C-c C-c'
  > nevertheless?  Or else, maybe we might choose another binding?

The Emacs server (see the emacsclient program) uses C-x #, and since
we can probably assume that the server-edit binding is not needed in
buffers created by M-m p...

A way to override the binding would the as follows: In M-m p, you ask
for a major mode to use.  You then execute the major mode function.
After that, you make a copy of the current local keymap and tell the
current buffer to use that copy as the local keymap.  Since this is a
unique Lisp object, you can redefine the C-c C-c binding without
clobbering the normal c-mode-map (say).

kai
-- 
Abort this operation?   [Abort]  [Cancel]


      reply	other threads:[~1999-04-26 15:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-04-26 14:50 François Pinard
1999-04-26 15:14 ` Kai.Grossjohann [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=vafogkbmn1h.fsf@ramses.cs.uni-dortmund.de \
    --to=kai.grossjohann@cs.uni-dortmund.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).