ActiveState Community

PyQt 4.5 CIX for Komodo Edit & IDE (with doc strings / signatures / types)

Posted by wuub on 2009-06-07 14:51
OS: All / Any

Hi All,

I was not pleased with automatically generated PyQt code intelligence available in Komodo. I decided that using a different approach might be a good idea and — as far as I can tell — it worked. :) You can download the results from here or from my homepage http://wuub.net.

Please let me know if you like it/use it.

--
wuub

AttachmentSize
showcase.png27.84 KB
PyQt.zip387.37 KB
pyqtdocgen.py_.txt10.07 KB

toddw | Mon, 2009-06-08 10:57

Hi Wuub,

Out of curiosity, how do you generating the PyQt API catalog?

Cheers,
Todd

wuub | Mon, 2009-06-08 11:17

Hi Todd,

All you need is:

1 lazy programmer
1 copy of PyQt4 API Reference
1 rainy Sunday
16 regular expressions 

As a result you'll get one butt ugly python script and one api catalog :) It is not perfect, but IMO was worth the effort.

--
wuub

toddw | Mon, 2009-06-08 11:22

Yes, using API reference manuals is usually vastly superior to what the introspection can determine.

Would you mind sharing the script and/or adding it to the OpenKomodo repository so others can use it to generate their own PyQt catalogs?

Cheers,
Todd

wuub | Sun, 2009-07-05 14:10

Hi Todd,

I was planning to clean up the pyqtdocgen.py before showing it to others, but never found enough time to do it, so I'm posting it "AS IS" (updated first post).

It has proven to be surprisingly problem free for a proof-of-concept/throw-away/one-time-use-only script. I've created 4.5.2.cix using python3.1 without any significant changes to the source. Butt ugly, but works :)

Edit:
It's a shame that Komodo's CI does not handle multiple methods with the same name. I know, I know, dynamic languages, but multiple dispatch is not uncommon even in python or ruby. Maybe it's worth investigating?

--
wuub

wuub | Tue, 2009-07-14 11:36

Small update :)