[wingide-users] Scripting search

Porlo pazerp at hotmail.com
Fri Oct 26 17:03:42 EDT 2012

Can anyone give me any tips on using the search API? Using [wingapi.py] in
conjunction with [editor-extensions.py] I've had some success in writing a
couple of very basic scripts, and now I'd like to have a go at writing a
third search script. Unfortunately I can't find any examples - either in the
docs or on the internet - which subclass CAPISearch. Thus far I think I've
managed to run  a search, but I can't fathom how to process the results.

def remove_debug_statements():
    doc = wingapi.gApplication.GetActiveDocument()
    f = doc.GetFilename()
    searcher = wingapi.CAPISearch("^.+# debug-assist$", match_case=True,
    # now what?

View this message in context: http://wingide.992054.n4.nabble.com/Scripting-search-tp4655283.html
Sent from the WingIDE - User mailing list archive at Nabble.com.

More information about the wingide-users mailing list