简体   繁体   中英

Python syntax highlighting / Intellisense?

I've started messing around with Google App Engine, writing Python.

I love Visual Studio for many reasons, but currently my.py files just look like text.

I've searched the web looking for a way to get it to highlight python files (intellisense would be a nice bonus, but not required) but turned up nothing.

There are other questions on SO about this, but all the answers point at different IDEs, or installing IronPythonStudio (which seems overkill since I only want to colouring, and it might behave differently being geared at .NET anyway).

Does anyone know how to simple get VS to highlight Python? Is it really that uncommon? :(

http://pytools.codeplex.com/

This is a replacement for IronPythonStudio and works well with VS2010. As for python, you can point it at any python directory library (including Ironpython, etc) for intellisense. Best part is, it's free.

Under Windows you could use Notepad ++ . It has syntax highlight for the python and is rather functionally rich, lightweight editor.

Thanks for all the responses. I did scan through some Python IDEs (and their screenshots) and decided to check out IronPythonStudio. My.py files now get colour coded nicely, and there's some intellisense:) Unfortunately Ctrl+K,D doesn't work, but it's much nicer to code than the plain yellow text I had earlier.

For anyone that's a massive Visual Studio fanboy like me, IronPythonStudio is definitely better than just coding it as text;o)

Unfortunately, I don't think there is any way to integrate VS with python.

If you want something not too heavyweight, you can use Komodo edit , - it is quite good for small-to-medium projects. You can use pydev+aptana studio or pydev+eclipse for bigger stuff. It is by no means lightweight, but pydev has some nice tools shipped with it (preconfigured), such as pylint.

As for code-completion, in my opinion, all python editors/IDE are a bit lacking in that area, but that is because of python's dynamic nature (in short, you can't figure what the code does before actually running it), so it can't be considered an IDE's flaw, or anyone's flaw for that matter.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM