From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: rusi Newsgroups: gmane.emacs.help Subject: Re: how to change the indentation style of emacs Date: Sun, 23 Jan 2011 01:37:24 -0800 (PST) Organization: http://groups.google.com Message-ID: <4482221e-b6ad-4db0-bfaf-a651bc6ec4e5@o14g2000yqe.googlegroups.com> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1295775685 28553 80.91.229.12 (23 Jan 2011 09:41:25 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 23 Jan 2011 09:41:25 +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 Jan 23 10:41:21 2011 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PgwRh-0001Pd-Tb for geh-help-gnu-emacs@m.gmane.org; Sun, 23 Jan 2011 10:41:18 +0100 Original-Received: from localhost ([127.0.0.1]:46542 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PgwRg-0004Jd-Sc for geh-help-gnu-emacs@m.gmane.org; Sun, 23 Jan 2011 04:41:16 -0500 Original-Path: usenet.stanford.edu!postnews.google.com!o14g2000yqe.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 28 Original-NNTP-Posting-Host: 116.73.35.230 Original-X-Trace: posting.google.com 1295775444 27680 127.0.0.1 (23 Jan 2011 09:37:24 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Sun, 23 Jan 2011 09:37:24 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: o14g2000yqe.googlegroups.com; posting-host=116.73.35.230; posting-account=mBpa7woAAAAGLEWUUKpmbxm-Quu5D8ui User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.13) Gecko/20101203 Firefox/3.6.13,gzip(gfe) Original-Xref: usenet.stanford.edu gnu.emacs.help:184504 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:78667 Archived-At: On Jan 22, 8:22=A0pm, Anand Dhanakshirur wrote: > Hi, > I am using emacs for c and c++ files. > > 1. Presently(default), In a C program, > after "for" loop, the next line(the next line starting with > "{" is indented(shifted) by 2 spaces. > I want to change this. > I want the next line is not shifted by 2 spaces when i press TAB key.(for= indentation) > basically > Now it is, for (i=3D0;i<10; i++) > =A0 =A0 =A0 =A0 =A0 =A0 =A0{ > =A0 =A0 =A0 =A0 =A0 =A0 =A0} > > I want this to be changed as > =A0 =A0 =A0 =A0 =A0 =A0for (i=3D0; i<10;i++) > > 2 .One more thing want to do. > after opening for loop of if condition, > the next line is getting shiftedby 2 spaces. > I want the next line to be shifted by 4 spaces. > > How to do these 2 things? Have you seen and tried http://www.emacswiki.org/emacs/IndentingC (especially different styles)?