[TxMt] Re: TextMate Code Completion

Ed Singleton singletoned at gmail.com
Thu Dec 7 09:44:47 UTC 2006


On 06/12/06, Jacob Rus <jrus at hcs.harvard.edu> wrote:
> For python, it would be great if we could get the whole standard
> library, though it's going to be a bit tricky, given how imported
> modules can be renamed, etc.

Some aspects of Python would be reasonably easy.  Most import
statements are at the top of the file and are easy to parse.  One
could write a command that does a dir() on each of those modules, and
when you type the module name followed by a dot, it offers the
contents of that dir().  It could be activated on typing dot, which
then scans back for the last whole word and sees if it knows that as a
module.

I'd be willing to have a go at this, but I don't know how to present a
drop down or scan back for the last word when a dot is pressed.  I'll
see if I can get the import parsing working though as a starter.

Ed



More information about the textmate mailing list