From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Perry Smith Newsgroups: gmane.emacs.help Subject: Re: question about indenting Date: Fri, 15 Jul 2011 07:49:29 -0500 Message-ID: <4B844315-239F-4935-8FE6-58C8DCD47779@gmail.com> References: <95462880.20110715090917@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: multipart/alternative; boundary=Apple-Mail-2--432995875 X-Trace: dough.gmane.org 1310734299 7342 80.91.229.12 (15 Jul 2011 12:51:39 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 15 Jul 2011 12:51:39 +0000 (UTC) Cc: help-gnu-emacs@gnu.org, pingved@gmail.com To: C K Kashyap Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Jul 15 14:51:34 2011 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Qhhrh-0007cW-Nc for geh-help-gnu-emacs@m.gmane.org; Fri, 15 Jul 2011 14:51:33 +0200 Original-Received: from localhost ([::1]:36272 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qhhrg-0003ya-KM for geh-help-gnu-emacs@m.gmane.org; Fri, 15 Jul 2011 08:51:32 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:48153) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qhhpo-0003y0-7c for help-gnu-emacs@gnu.org; Fri, 15 Jul 2011 08:49:37 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qhhpm-0004dm-OO for help-gnu-emacs@gnu.org; Fri, 15 Jul 2011 08:49:35 -0400 Original-Received: from mail-iw0-f169.google.com ([209.85.214.169]:40155) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qhhpm-0004di-Gd for help-gnu-emacs@gnu.org; Fri, 15 Jul 2011 08:49:34 -0400 Original-Received: by iwn8 with SMTP id 8so1258209iwn.0 for ; Fri, 15 Jul 2011 05:49:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=subject:mime-version:content-type:from:in-reply-to:date:cc :message-id:references:to:x-mailer; bh=+vpF12vPXfiRNyPO9dg/S1xdTDgFb+InRCSiVUSvyNA=; b=IhwjXIDJz9sSR1tKb6PQ/vzDYlffFU3JzoLq+PwsLtytShl7EO6HMyjR+VAQDBF9Oe 52lbs1r6ZAP03C6Cz0PJCH8NXxFDY0KaE8KcbXHeYI+YF6MbMYRUWqdMWo2FfrOqy2Z0 hDE8GtNsD6+tnHaglgQVbKYa8Gd4OfuSUJOXU= Original-Received: by 10.43.131.6 with SMTP id ho6mr3204683icc.357.1310734173211; Fri, 15 Jul 2011 05:49:33 -0700 (PDT) Original-Received: from [10.0.0.4] ([64.128.19.234]) by mx.google.com with ESMTPS id c2sm838166ibd.22.2011.07.15.05.49.31 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 15 Jul 2011 05:49:32 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.1084) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.214.169 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:81596 Archived-At: --Apple-Mail-2--432995875 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii On Jul 15, 2011, at 4:04 AM, C K Kashyap wrote: > Hello to all! > How i can indent strings in any mode, c-mode for example like this: >=20 > void Test(void) { > (3space)DWORD abc; > (4space)exit(0); > (4space){ > (4space)(3space)DWORD a; > (4space)(4space)exit(0); > (4space)} > } >=20 >=20 >=20 > You could select the region (using the mouse or M-h) and then press = M-C-\ - this should indent the code. I think he is asking about how to set up c mode. Noticed that his = variable declarations are indented differently. If you do M-x customize, then pick Programming, Languages, C you will = get to a list of customizable options that affect how things are = indented, etc.=20 I don't see something specific for variable declarations though. = Perhaps someone else will chime in with some suggestions. Good luck Perry --Apple-Mail-2--432995875 Content-Transfer-Encoding: 7bit Content-Type: text/html; charset=us-ascii
On Jul 15, 2011, at 4:04 AM, C K Kashyap wrote:

Hello to all!
How i can indent strings in any mode, c-mode for example like this:

void Test(void) {
 (3space)DWORD abc;
 (4space)exit(0);
 (4space){
 (4space)(3space)DWORD a;
 (4space)(4space)exit(0);
 (4space)}
}



You could select the region (using the mouse or M-h) and then press M-C-\ - this should indent the code.

I think he is asking about how to set up c mode.  Noticed that his variable declarations are indented differently.

If you do M-x customize, then pick Programming, Languages, C you will get to a list of customizable options that affect how things are indented, etc. 

I don't see something specific for variable declarations though.  Perhaps someone else will chime in with some suggestions.

Good luck
Perry


--Apple-Mail-2--432995875--