From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Lennart Borgman (gmail)" Newsgroups: gmane.emacs.devel Subject: Defining keys in derived modes Date: Wed, 28 Feb 2007 10:37:14 +0100 Message-ID: <45E54D4A.601@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1172655520 1137 80.91.229.12 (28 Feb 2007 09:38:40 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 28 Feb 2007 09:38:40 +0000 (UTC) To: Emacs Devel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Feb 28 10:38:33 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HMLGZ-0000SA-4h for ged-emacs-devel@m.gmane.org; Wed, 28 Feb 2007 10:38:31 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HMLGZ-0006oB-Gu for ged-emacs-devel@m.gmane.org; Wed, 28 Feb 2007 04:38:31 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HMLFM-0006Pb-NA for emacs-devel@gnu.org; Wed, 28 Feb 2007 04:37:16 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HMLFL-0006P6-6A for emacs-devel@gnu.org; Wed, 28 Feb 2007 04:37:16 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HMLFL-0006P2-1P for emacs-devel@gnu.org; Wed, 28 Feb 2007 04:37:15 -0500 Original-Received: from ch-smtp02.sth.basefarm.net ([80.76.149.213]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1HMLFK-0003E4-Ba for emacs-devel@gnu.org; Wed, 28 Feb 2007 04:37:14 -0500 Original-Received: from c83-254-145-24.bredband.comhem.se ([83.254.145.24]:63901 helo=[127.0.0.1]) by ch-smtp02.sth.basefarm.net with esmtp (Exim 4.63) (envelope-from ) id 1HMLFH-0003Rd-7Q for emacs-devel@gnu.org; Wed, 28 Feb 2007 10:37:11 +0100 User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.9) Gecko/20061207 Thunderbird/1.5.0.9 Mnenhy/0.7.4.666 X-Antivirus: avast! (VPS 000718-0, 2007-02-27), Outbound message X-Antivirus-Status: Clean X-Scan-Result: No virus found in message 1HMLFH-0003Rd-7Q. X-Scan-Signature: ch-smtp02.sth.basefarm.net 1HMLFH-0003Rd-7Q 108722b079558e99cdd32182b8acf117 X-detected-kernel: Linux 2.6? (barebone, rare!) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:67010 Archived-At: I have the following code (define-derived-mode nxhtml-part-mode nxhtml-mode "nXhtmlPart" "Mode for editing part of an XHTML file. Based on `nxhtml-mode." (nxml-part-mode-enter)) (defvar nxhtml-part-mode-map (let ((map (make-sparse-keymap))) (set-keymap-parent map nxhtml-mode-map) (define-key map [(control ?c) ?t] 'nxhtml-part-toggle-invisible-hf) map) "Keymap for `nxhtml-part-mode'.") The keymap nxhtml-mpart-mode map then gets the doc string from above. I would expect it to also contain the definition of C-c t, but it does not. Should it behave this way? How should key bindings be done for derived modes?