From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Shug Boabby" Newsgroups: gmane.emacs.help Subject: Python indent region Date: 10 Jul 2006 03:49:11 -0700 Organization: http://groups.google.com Message-ID: <1152528551.081898.38570@35g2000cwc.googlegroups.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: sea.gmane.org 1152531639 4065 80.91.229.2 (10 Jul 2006 11:40:39 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 10 Jul 2006 11:40:39 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Jul 10 13:40:37 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 1Fzu7u-0001yc-BM for geh-help-gnu-emacs@m.gmane.org; Mon, 10 Jul 2006 13:40:34 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Fzu7t-0006pE-D6 for geh-help-gnu-emacs@m.gmane.org; Mon, 10 Jul 2006 07:40:33 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!postnews.google.com!35g2000cwc.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 15 Original-NNTP-Posting-Host: 129.215.188.172 Original-X-Trace: posting.google.com 1152528555 7826 127.0.0.1 (10 Jul 2006 10:49:15 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Mon, 10 Jul 2006 10:49:15 +0000 (UTC) User-Agent: G2/0.2 X-HTTP-UserAgent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X; en-us) AppleWebKit/418.8 (KHTML, like Gecko) Safari/419.3,gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: 35g2000cwc.googlegroups.com; posting-host=129.215.188.172; posting-account=jQz-EQ0AAABiniXWq8YyRVQ60t_LIYwt Original-Xref: shelby.stanford.edu gnu.emacs.help:140258 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:35883 Archived-At: Hello all, As you may know, python recognises blocks of code by their indentation level. Emacs handles this very well when writing code. However, Emacs does not handle indenting/unindenting whole regions very well. I was wondering if somebody could please write me some lisp code that would add 4 spaces (or the user defined indent character) to the beginning of each line in a region, and a complementary function to reduce each line in a region by one indentation level. These would really help out when doing some code restructuring in Python. Thanks, Shug