How do you program in Python?

James fphsml at gmail.com
Sun Jul 3 21:50:58 CEST 2005



Peter Hansen wrote:
> anthonyberet wrote:
> > What I would really like is something like an old-style BASIC
> > interpreter, in which I could list, modify and test-run sections of
> > code, to see the effects of tweaks, without having to save it each time,
> > or re-typing it over and over (I haven't even worked out how to cut and
> > paste effectively in the IDLE environment).
>
> I do all my work using Scite (a nice free editor that was built to
> demonstrate the Scintilla plugin that can also be used in Python
> programs through things like the StructuredTextControl in wxPython),
> with the auto-save-on-loss-of-focus feature enabled, and a command
> prompt open in another window.
>
> I edit in the Scite window, hit Alt-Tab (under Windows XP) to change
> focus to the cmd console (and instantly all my modified files are
> saved), press the Cursor Up key to retrieve the previous command (which
> is generally the name of my script, or a command like "python
> myscript.py"), and hit Enter to execute it.
>
> So, any time I need to test the changes, I hit four keys (which at this
> point is understandably more like a "chord" that I hit without direct
> awareness of it) and I'm done.  Sounds pretty close to old-style BASIC
> and since I've come that route too (in the distant past), this may not
> be a coincidence.

Just curious. Why do you Alt-Tab to a console when you can just hit F5
in SciTE? That's just 1 key instead of 4. And yes, SciTE can autosave
here too.




More information about the Python-list mailing list