Find Points of Use
Wing IDE is able to find the locations where a symbol is used in the current project's Python files. To start a search, select or place the cursor in a symbol and then use Find Points of Use in the Source menu or editor's context menu (right-click) or Alt-click on a symbol. Lines with matching symbols will be displayed in the Uses tool and clicking on a match will display it in an editor.
Since Python is a dynamic language, it is sometimes impossible to determine for certain whether a match is the same symbol. Matches are assigned a likelyhood of being correct, as follows:
- Likely: The original symbol and found symbol resolve to the same definition so that using Goto Definition on each will end up in the same place.
- Possible: Either the original symbol or the found symbol don't resolve to any definition.
- Unlikely: The original symbol resolves to a different definition than the found symbol.
Possible matches are listed with a question mark (?) preceding the filename and unlikely matches are listed with double question mark (??) preceding the filename. Only likely and possible matches are displayed by default. The display of possible and unlikely matches may be toggled via the Options menu on a per-search basis.
When searching for uses of a class __init__ or __new__ methods, the results will include matches where the class or a derived class is used by their original name to create new instances.
If Wing is failing to see matches as resolving to the same point of definition, it may help to add to the Python Path in Project Properties so that the source analysis engine can resolve module imports.
Completed searches are stored in the Uses tool and can be referenced by clicking on the drop down menu at the top of the tool and deleted by clicking on the close icon. Note that searches do not automatically refresh as code is modified, but may be updated manually with Refresh in the Options menu.