From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Kpoxman (sent by Nabble.com)" Newsgroups: gmane.emacs.help Subject: Re: Novice question: my add-hook binding for c-mode doesnt work :( Date: Fri, 2 Dec 2005 01:10:36 -0800 (PST) Message-ID: <1749159.post@talk.nabble.com> References: <1732372.post@talk.nabble.com> <8764q8yorw.fsf@totoz.gnu-rox.org> <20051202070701.B40573F28@rocksteady.printf.se> Reply-To: Kpoxman NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1212475170==" X-Trace: sea.gmane.org 1133523400 6078 80.91.229.2 (2 Dec 2005 11:36:40 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 2 Dec 2005 11:36:40 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Dec 02 12:36:38 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1Ei9C7-0005G1-3o for geh-help-gnu-emacs@m.gmane.org; Fri, 02 Dec 2005 12:35:15 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ei9Be-000726-MA for geh-help-gnu-emacs@m.gmane.org; Fri, 02 Dec 2005 06:34:47 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Ei71p-0002ur-B5 for help-gnu-emacs@gnu.org; Fri, 02 Dec 2005 04:16:30 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Ei6wH-0002Fx-Pb for Help-gnu-emacs@gnu.org; Fri, 02 Dec 2005 04:10:47 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ei6wD-0002F3-0O for Help-gnu-emacs@gnu.org; Fri, 02 Dec 2005 04:10:42 -0500 Original-Received: from [72.21.53.35] (helo=talk.nabble.com) by monty-python.gnu.org with esmtp (TLS-1.0:RSA_AES_128_CBC_SHA:16) (Exim 4.34) id 1Ei6wA-0006of-6o for Help-gnu-emacs@gnu.org; Fri, 02 Dec 2005 04:10:39 -0500 Original-Received: from localhost ([127.0.0.1] helo=talk.nabble.com) by talk.nabble.com with esmtp (Exim 4.50) id 1Ei6w8-0004h7-PB for Help-gnu-emacs@gnu.org; Fri, 02 Dec 2005 01:10:36 -0800 Original-To: Help-gnu-emacs@gnu.org In-Reply-To: <20051202070701.B40573F28@rocksteady.printf.se> X-Nabble-Sender: Nabble Forums X-Nabble-From: Kpoxman X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:31608 Archived-At: --===============1212475170== Content-Type: multipart/alternative; boundary="----=_Part_280_26946191.1133514636774" ------=_Part_280_26946191.1133514636774 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Thank you guys! So, the correct code is (I've tested and it works): (add-hook 'c-mode-common-hook '(lambda () (define-key c-mode-base-map (kbd "M-o") 'kpox-switch-h-cpp)) ) -- Sent from the Emacs - Help forum at Nabble.com: http://www.nabble.com/Novice-question%3A-my-add-hook-binding-for-c-mode-doesnt-work-%3A%28-t651747.html#a1749159 ------=_Part_280_26946191.1133514636774 Content-Type: text/html; charset=us-ascii Content-Transfer-Encoding: 7bit Thank you guys!
So, the correct code is (I've tested and it works):

(add-hook 'c-mode-common-hook
          '(lambda () (define-key c-mode-base-map (kbd "M-o") 'kpox-switch-h-cpp))
          )


Sent from the Emacs - Help forum at Nabble.com:
Re: Novice question: my add-hook binding for c-mode doesnt work :( ------=_Part_280_26946191.1133514636774-- --===============1212475170== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Help-gnu-emacs mailing list Help-gnu-emacs@gnu.org http://lists.gnu.org/mailman/listinfo/help-gnu-emacs --===============1212475170==--