Marco wrote:That's to match terms not on the same line. The dot matches everything except \r\n, while [\s\S] matches newlines too.
Ah! That makes sense... I didn't realize XY's dot didn't include line breaks.

Thanks!
As for karimmaster101's question...
I don't think XY's search is well-suited for what you're attempting. You might be better served looking for another program for this task. I don't have a suggestion but someone else here might.
That said, if you want to stick with XY then I'd suggest using a tags and multiple searches approach.
Say we want to search for files containing 'farm', 'house', and 'blues' in no particular order.
- Perform the search for one word - 'farm'.
- Select all results.
- In the menu select Favorites > Add Tags.
- In the Add Tags dialog create a unique tag for these items - 'contains:farm'.
- Now in the Find Files > Tags tab, enable Tags and in the corresponding field put that unique tag 'contains:farm'. (If in the previous step you checked Add new tags to tag list you can use the Select Tags... button here.)
- Now change the Contents tab to the next word 'house' and search again.
- Tag the results 'contains:house'.
- Update the Tags tab to search 'contains:farm , contains:house' (',' is logical 'AND' so this means items tagged with both. '|' is 'OR' and would be items tagged with either.)
- Now search for items containing 'blues' to arrive at the final results.
You might be able to speed up the process if you can make an educated guess and search for the words in order of least to most-frequently used.
Once you're done you can find all the tagged items by searching for items tagged 'contains:farm | contains:house' and use
Favorites > Remove Tags by List or
Remove All Tags to remove the tags. But if you do this task frequently it might make more sense to make the tags more permanent and occasionally perform unrestricted searches just to add tags to items containing your search words. Doing so could allow you to restrict the search to tagged items from the beginning.
It is possible to automate this task further with scripting, but neither approach I can think of is nice and simple. One way would be to bypass XY's search entirely and have the script read every file looking for the words, but this will be slower. The other requires creating/modifying a search template INI file to perform the searches with the
LoadSearch scripting command - not difficult but not ideal either - and making it flexible becomes a challenge.
Sorry that this isn't a quick solution, or what you were likely hoping for, but hopefully it still helps!
