From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "jronald" Newsgroups: gmane.emacs.help Subject: Helpful, thans. Date: Fri, 15 Sep 2006 02:31:54 +0800 Organization: Bentium Ltd. (CN99) Message-ID: References: <1158247308.610920.315590@e3g2000cwe.googlegroups.com> NNTP-Posting-Host: main.gmane.org X-Trace: sea.gmane.org 1158259317 2877 80.91.229.2 (14 Sep 2006 18:41:57 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 14 Sep 2006 18:41:57 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Sep 14 20:41:54 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1GNw9g-0005us-OO for geh-help-gnu-emacs@m.gmane.org; Thu, 14 Sep 2006 20:41:45 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GNw9g-0008Ec-Ab for geh-help-gnu-emacs@m.gmane.org; Thu, 14 Sep 2006 14:41:44 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!bloom-beacon.mit.edu!news.cn99.com!news.yaako.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 31 Original-NNTP-Posting-Host: 222.64.176.17 Original-X-Trace: news.yaako.com 1158258729 10362 222.64.176.17 (14 Sep 2006 18:32:09 GMT) Original-X-Complaints-To: usenet@news.yaako.com Original-NNTP-Posting-Date: Thu, 14 Sep 2006 18:32:09 +0000 (UTC) X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.2670 X-RFC2646: Format=Flowed; Original X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2670 Original-Xref: shelby.stanford.edu gnu.emacs.help:141750 Original-To: help-gnu-emacs@gnu.org 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:37372 Archived-At: ??????:1158247308.610920.315590@e3g2000cwe.googlegroups.com... > jronald wrote: >> By consulting c-default-style in emacs's doc, >> it says: >> >> c-default-style's value is >> ((java-mode . "java") >> (other . "gnu")) >> >> but I'm editing a .cpp file. > > c-default-style is a CC mode variable. CC mode deals with all > langauges that are similar to C, such as Java, C++, C, and lots of > other obscure langs. When you see "c-mode" in a buffer it means that > you're using a C mode that is internally part of CC-mode. > > As a result this variable can have values for every one of these > programming languages. For example, you can do:- > > (setq c-default-style "k&r") ;; Use kernigham & ritchie style for > everything > or specifying different styles for each mode that CC-mode controls.. > (setq c-default-style '((java-mode . "java") (c-mode . "gnu") (other . > "whitesmith"))) > > I think the name is rather confusing, it probably should be changed. >