Compile Replacement With \n

I thought I’d get rid of empty lines by replacing one or more newlines with one newline. That failed because, as the manual says in 11.2.1,

“The find tool cannot work with whitespace symbols, such as \n and \t in the replacement field. Use native whitespace characters instead.”

My question is simple. What ARE the native whitespace equivalents of \n and \t?

Hold down ‘Alt’ and press Return or Tab to enter them into the Find dialog. I assume that is what is meant.

:slight_smile:

Mark

That works in the Find dialog, but not in Compile Replacement.

I realize there are other ways to do this, but I’m trying to figure out how to use RegEx replacements in Scrivener . There’s no universe in which “option return” = “native whitespace”, either.

THIS works, on the other hand, and I’d imagine it’s more efficient.

Hm, ⌥␣ and ⌥↹ both work for replacements for me, but you cannot see them in the dialog, unless you select and you can see empty space selection:

Right you are, mea culpa again. I still wonder what “native whitespace” means.

Native as in how the macOS user interface handles these characters, as literals in the field (and by default, awkwardly so since they are invisible, we added display of them in a few contexts, but in things like simple text entry fields like Replacements, they remain invisible.

I’ve patched up this spot of the manual to be clearer.