Improve the text search in editor window

When working on my HTML source, I like to collapse the portions of the code that I consider finished. However, when I search for some text that occurs in the collapsed portion, the code is un-collapsed.

It would be nice to have an option to restrict the search (and replace) function to operate only on the portion of the code that is currently un-collapsed.