From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: harven Newsgroups: gmane.emacs.help Subject: Re: beautifying the current line Date: Thu, 24 Apr 2008 03:10:57 -0700 (PDT) Organization: http://groups.google.com Message-ID: <0ea9fd54-4790-4984-a0b2-0689482d330b@a22g2000hsc.googlegroups.com> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1209033653 14350 80.91.229.12 (24 Apr 2008 10:40:53 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 24 Apr 2008 10:40:53 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Apr 24 12:41:28 2008 connect(): Connection refused 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.50) id 1Joyt8-0000mc-A9 for geh-help-gnu-emacs@m.gmane.org; Thu, 24 Apr 2008 12:41:14 +0200 Original-Received: from localhost ([127.0.0.1]:52167 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JoysS-0008Bp-FA for geh-help-gnu-emacs@m.gmane.org; Thu, 24 Apr 2008 06:40:32 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!postnews.google.com!a22g2000hsc.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 33 Original-NNTP-Posting-Host: 82.240.200.149 Original-X-Trace: posting.google.com 1209031857 4476 127.0.0.1 (24 Apr 2008 10:10:57 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Thu, 24 Apr 2008 10:10:57 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: a22g2000hsc.googlegroups.com; posting-host=82.240.200.149; posting-account=hanW0AoAAADuR-PIr5jGeb298Y3jGR7p User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14,gzip(gfe),gzip(gfe) Original-Xref: shelby.stanford.edu gnu.emacs.help:158146 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:53510 Archived-At: On Apr 23, 11:26 pm, TheLonelyStar wrote: > Hi, > > When I press tab in emacs (while editing an c++ file), it indents the > current line. Very good! > I was wondering if maybe emacs could do even more. Look at this example: > What if pressing tab on something like this: > > LongTypeName a; > int b; //<-press tab on this line > > Would result in: > > LongTypeName a; > int b; > > Like running astyle. But only the current line is changed. > I do not want to change the whole buffer, just the current line. > I also do not want to select a region for this. Just press tab, like I do > when I want indention. > > Is this possible? > Thanks! > Nathan > -- > View this message in context:http://www.nabble.com/beautifying-the-current-line-tp16834831p1683483... > Sent from the Emacs - Help mailing list archive at Nabble.com. If you are looking for alignment of assignments, try M-x align- current It works on the current section, I think that's what you want. Have a look on the emacs wiki, in CategoryAlignment, for more details.