I need to search a Scrivener draft for (new paragraph) (quote) (space space) (any text character). How do I do that?
If you ditch out the “(any text character)”, and rather do the filtering visually yourself for that condition,
this would work (without the need for a Regex formula) :
(Search in a scrivening of your target documents.)
Edit / Find / Find...
[Ctrl-Enter] " space space
(Note that it won’t find the very first paragraph of a document, as the return/enter
is absent. You’d have to visually inspect those yourself.)
. . . . . . . . .
Else, for a Regex tester and legend :
(I am not versed enough to give you a Regex answer myself, but some of the other users here are. )
There may be a better variation of this depending what you want to do with the match when you find it, but using a RegEx search, ^("|“|”) {2}\S
will find new lines (aka new paragraphs) beginning with a double quote (straight or curly either direction; you could trim that if you don’t need all the options), two regular space characters, and then a non-space character (which is how I interpreted “any text character”; this would exclude carriage returns and tabs, for example, but include punctuation).
RegEx search can be used as a project search as well as the document Find tool; just change the search operator—magnifying glass button menu in the search bar or the dropdown under Find Options in the other.
Thank you, but this is above my head! :-0 What I’m searching for is:
quote space space followed by a word. (Quote space space alone gives me a zillion at the end of paragraphs.
The problem is I don’t know how to ask for “any word.” I think it may be “?” in Word and “*” in others, but in Scrivener? Neither of these work.
Search for Return quote space space
like I’ve shown above.
Otherwise, just set the search for “Regex”, and paste what @MimeticMouton gave you for a formula as what to search for.
MimeticMouton most likely gave you the best of both possibilities. – Mine involves manual steps on your part.
. . . . . . .
Any word in a Regex for Scrivener would be *space
, I believe.
Thank you, Vincent, but when I type ¶ in the search box, nothing comes up. There’s something basic I’m not getting!
Ctrl+Enter (Under Windows, the least.)
You can copy/paste it from the editor, too.
You’re asking for a special search and RegEx is how to do that.
As @MimeticMouton already provided, the RegEx is:
\n("|"|Ęş) {2}(\S)
which finds:
Return
" Any character
and can be replaced by:
\n\1\2
to read:
Return
"Any character
Here’s the saved RegEx from Regex 101 : https://regex101.com/r/EOn1qu/1
Thank you so much! I finally discovered the RegEX option in the search bar (duh!), and I’ve got it now. I’ve learned a lot … thank you for your patience!