From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.help Subject: Re: questions about the value of local variables Date: Sun, 12 May 2013 17:14:16 +0000 (UTC) Organization: muc.de e.V. Message-ID: References: NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1368380701 12643 80.91.229.3 (12 May 2013 17:45:01 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 12 May 2013 17:45:01 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun May 12 19:45:01 2013 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UbaKT-0001bF-AK for geh-help-gnu-emacs@m.gmane.org; Sun, 12 May 2013 19:45:01 +0200 Original-Received: from localhost ([::1]:59472 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UbaKS-0001kK-RU for geh-help-gnu-emacs@m.gmane.org; Sun, 12 May 2013 13:45:00 -0400 Original-Path: usenet.stanford.edu!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.freenet.ag!news.space.net!news.muc.de!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 29 Original-NNTP-Posting-Host: news.muc.de Original-X-Trace: colin.muc.de 1368378856 85801 193.149.48.2 (12 May 2013 17:14:16 GMT) Original-X-Complaints-To: news-admin@muc.de Original-NNTP-Posting-Date: Sun, 12 May 2013 17:14:16 +0000 (UTC) User-Agent: tin/1.9.6-20101126 ("Burnside") (UNIX) (FreeBSD/8.4-PRERELEASE (amd64)) Original-Xref: usenet.stanford.edu gnu.emacs.help:198403 X-Mailman-Approved-At: Sun, 12 May 2013 13:44:50 -0400 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:90669 Archived-At: Hongxu Chen wrote: > Hi, > I am using Emacs for some C/C++ coding. [ .... ] > Still another question, is there any good practice to set the > variables with proper hooks in c family programming language modes? > There seems quite a lot of hooks there > (`c-initialization-hook',`cc-mode-hook', `c-mode-hook', > `c-mode-common-hook', etc) and I just get lost. > Well, I don't think there's a `cc-mode-hook', but the others exist, yes. :-) Basic rule: put (the bulk of) your CC Mode customisations on `c-mode-common-hook'. If this doesn't work, you'll need one of the other hooks. It's all documented on page "CC Hooks" in the CC Mode manual. > -- > Regards, > Hongxu Chen -- Alan Mackenzie (Nuremberg, Germany).