Changing tab behavior in Python Interactive mode

A

Andrej Mitrovic

I've noticed that when running Python in interactive mode (via cmd on
windows), the first time I hit tab it will move 4 spaces to the right,
however each new tab will move 8 spaces instead of 4. Why this
inconsistent behavior? And how could I change this to be consistent
and always move only 4 spaces?
 
A

Andrej Mitrovic

The first tab you are starting four characters in due to the interpreter
already having printed ">>> ".

regards
 Steve
--
Steve Holden           +1 571 484 6266   +1 800 494 3119
PyCon is coming! Atlanta, Feb 2010  http://us.pycon.org/
Holden Web LLC                http://www.holdenweb.com/
UPCOMING EVENTS:        http://holdenweb.eventbrite.com/

I see. I wonder if I could modify this behavior.. I guess I'll have to
take a look at the source. Thanks anyway!
 
S

Steve Holden

Andrej said:
I see. I wonder if I could modify this behavior.. I guess I'll have to
take a look at the source. Thanks anyway!

I's nothing to do with the source: it isn't the interpreter that's
deciding where the "tab stops" are, it's the console window the
interpreter is running in.

regards
Steve
 
S

Steve Holden

Andrej said:
I see. I wonder if I could modify this behavior.. I guess I'll have to
take a look at the source. Thanks anyway!

I's nothing to do with the source: it isn't the interpreter that's
deciding where the "tab stops" are, it's the console window the
interpreter is running in.

regards
Steve
 
A

Andrej Mitrovic

I's nothing to do with the source: it isn't the interpreter that's
deciding where the "tab stops" are, it's the console window the
interpreter is running in.

regards
 Steve
--
Steve Holden           +1 571 484 6266   +1 800 494 3119
PyCon is coming! Atlanta, Feb 2010  http://us.pycon.org/
Holden Web LLC                http://www.holdenweb.com/
UPCOMING EVENTS:        http://holdenweb.eventbrite.com/

I see. Well I'm nitpicking here, it's not all that important (I just
use cmd when I'm trying out small pieces of code). And I doubt there's
a tabstop setting for cmd that I could use.

Thanks for all your help!
 
T

Terry Reedy

I see. Well I'm nitpicking here, it's not all that important (I just
use cmd when I'm trying out small pieces of code). And I doubt there's
a tabstop setting for cmd that I could use.

Nope. I checked the properties dialog (rt click upper left icon).
You might want to turn on quickeditmode (as admin).

Terry Jan Reedy
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top