473,407 Members | 2,306 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,407 software developers and data experts.

Emacs python mode indent levels

Since Python has no explcit ends to blocks, emacs doesn't always know
the right indentation level to use. And <del> doesn't seem to be very
consistent (it always seems to go back 8 characters, which doesn't
help when the indent level is 4).

Another language where indentation is significant is Haskell. The
emacs Haskell mode has an excellent solution to the problem: Pushing
<tab> cycles through the various possible indentations.

Does anyone know if anything like this is possible with Python mode?
Or are there any other popular solutions?

(I am not an elipser)

--
John.
Jul 18 '05 #1
2 2744

John> Another language where indentation is significant is Haskell. The
John> emacs Haskell mode has an excellent solution to the problem:
John> Pushing <tab> cycles through the various possible indentations.

John> Does anyone know if anything like this is possible with Python
John> mode? Or are there any other popular solutions?

Probably. <wink>...

Feel free to file a feature request with the python-mode project on
SourceForge. If we get to it, we get to it.

Speaking of which, if you find reviewing and responding to bug/patch reports
for Python beneath you, perhaps you'd like to hone your ELisp chops a bit:

http://sf.net/projects/python-mode

Feel free to review submissions, fix bugs, etc. Operators are standing
by...

Skip

Jul 18 '05 #2
On 14 Jul 2004 20:22:07 -0700, John Fouhy <jf****@paradise.net.nz> wrote:
Since Python has no explcit ends to blocks, emacs doesn't always know
the right indentation level to use. And <del> doesn't seem to be very
consistent (it always seems to go back 8 characters, which doesn't
help when the indent level is 4).
are you using python-mode.el? It works fine here...
Another language where indentation is significant is Haskell. The
emacs Haskell mode has an excellent solution to the problem: Pushing
<tab> cycles through the various possible indentations.
I'd say go talk to the python-mode people [1]

Does anyone know if anything like this is possible with Python mode?
Or are there any other popular solutions?

(I am not an elipser)


does that mean you don't fit ellipses [2]? :-P
References:

1) http://python-mode.sf.net
2) http://groups.google.com/groups?thre...ing.google.com

--
John Lenton (jl*****@gmail.com) -- Random fortune:
bash: fortune: command not found
Jul 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Tuxtrax | last post by:
Hi all My editor of choice on linux for python, bar none, is xemacs. I love the python mode that detects a python file and handles indentation and coloration for me automagically. I have been...
0
by: Greg Novak | last post by:
I realize that this is a pretty esoteric question, but I'm not even getting any traction on it by myself. I believe that the problem has to do with signal handling for programs run underneath...
3
by: porterboy | last post by:
CONTEXT: I am using Emacs to edit Python code and sometimes also Matlab code. When I hit <return> in a loop of some sort, Emacs usually gets the nesting indentation right, which is particularly...
12
by: Rex Eastbourne | last post by:
Hi, I'm interested in running a Python interpreter in Emacs. I have Python extensions for Emacs, and my python menu lists "C-c !" as the command to run the interpreter. Yet when I run it I get...
12
by: Thomas Bartkus | last post by:
Does anyone use emacs together with both WordStar key bindings and python mode? I'm afraid that Wordstar editing key commands are burned R/O into my knuckles! I would like to play with emacs...
4
by: emin.shopper | last post by:
Emacs seems to freeze when doing certain shell commands on Microsoft Windows. The following is a simple example with Xemacs: ---------------------------------------------------------- ...
6
by: eugene.morozov | last post by:
Hello, Does anyone know how to make python-mode correctly indent nested lists and dictionaries. I hate indenting Django url patterns and Zope Archetypes schemas by hand, because python-mode...
3
by: Grant Edwards | last post by:
I've recently switched from Jed to Emacs for editing python source, and I'm still stumped as to how one indents or dedents a region of code. In Jed it's 'C-c <' or 'C-c >'. Google has found...
0
by: Malte Helmert | last post by:
skip@pobox.com wrote: One of the two modes (if memory serves, python.el) has an annoying bug/feature where indent-region is essentially implemented as "hit tab once on every line in the region"....
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.