Please could you add a real All Whole Words to the search capabilities
Rationale:
It seems not widely appreciated, though it is correctly described in the manual, that the “words” in “All Words”, and “Any Words” searches are not “words” in the sense of word as would be found by a regex between “\b” boundary delimiters, i.e. they’re any/all sub-string searches (maybe the current labelling arose because the search terms are seen/entered as space-delimited “words” in the search box, and it might be a tad too technical to refer to sub-string searches?)
This led to much confused discussion, and by way of workaround, development of an external software utility that would do precisely this.
It is needed as a separate option because it is not practical to do it in Scrivener using other tools: regex is the obvious choice, but creating a multiple word, any order regex, is time consuming and error prone. The workaround of doing a single word search “hoisting” the results, then searching within them, and iterating is just about viable for two words, but impractical for >2.
Use Cases:
Searching for people, things, adjectives etc. that occur frequently as substrings of other words. For example, I want to find all documents containing “John” and “Liz” excluding “Johnson” and Eliza", or “tab” and “hair” without hitting “table” and “chair”.
Even with my external utility, I cannot then go directly to the found documents (Unless there is an API to call Scrivener to open a particular content.rtf so that it is not some anonymous document but is properly located in the binder, etc.?)
NB One could also use such a capability to do character & other inventories based on user supplied lists; that would also be handy, e.g. for finding out in which document A & B first meet, or for continuity checking on things.
Extra
I don’t think this should be hard or time consuming to do, he said, speaking like a fully-detached manager: all * one needs to do is iterate over all docs in scope, repeating whole word searches per doc until either they all match or one match fails (early out). You already have the document iteration capability, the results presentation capability, etc. all you need to add is a multi-pass whole word loop per document. (* +UI update, documentation change, test…)
Absurd Complication to be ignored (Q: so why am I mentioning it?)
For myself, I am thinking about checking to see whether the search term is referred to within quotes, or “exists” outside them, then I’d have an even better idea who was in a scene and who had been referred to
Answer: so I can find this idea again
Thanks, Julian