could instead allow just one of each dialog to be openbut that' less functional cross-process change tests on quit though not quite as grievouspyedit also used to ignore changes in other open edit windows on quit in main windows as policyon quit in the guipop-up edit windows destroy themselves onlybut main edit windows run tkinter quit to end the entire program although all windows verify closes if their own content has changedother edit windows were ignored in the prior version--quitting main window could lose changes in other windows closed on program exit to do betterthis version keeps list of all open managed edit windows in the processon quit in main windows it checks them all for changesand verifies exit if any have changed this scheme isn' foolproof (it doesn' address quits run on widgets outside pyedit' scope)but it is an improvement more ultimate solution probably involves redefining or intercepting tkinter' own quit method to avoid getting too detailed herei'll defer more on this topic until later in this section (see the event coverage ahead)also see the relevant comments near the end of pyedit' source file for implementation notes new grep dialogthreaded and unicode-aware file tree search in additionthere is new grep option in the search pull-down menuwhich implements an external file search tool this tool scans an entire directory tree for files whose names match patternand which contain given search string names of matches are popped up in new nonmodal scrolled list windowwith lines that identify all matches by filenameline numberand line content clicking on list item opens the matched file in new nonmodal and in-process pyedit pop-up edit window and automatically moves to and selects the line of the match this achieves its goal by reusing much code we wrote earlierthe find utility we wrote in to do its tree walking the scrolled list utility we coded in for displaying matches the form row builder we wrote in for the nonmodal input dialog the existing pyedit pop-up window mode logic to display matched files on request the existing pyedit go-to callback and logic to move to the matched line in file grep threading model to avoid blocking the gui while files are searched during tree walksgrep runs searches in parallel threads this also allows multiple greps to be running at once and to overlap in time arbitrarily (especially useful if you grep in larger treessuch as python' own library or full source treesthe standard threadsqueuesand after timer loops technique we learned in is applied here--non-gui producer threads find matches and place them on queue to be detected by timer loop in the main gui thread pyedita text editor program/object