Conditional highlighting?


Is there a good way of setting up a means to highlight names with the same color throughout an entire body of text? Doesn’t necessarily need to be automatic and real time, just some way of selecting all incidences of a name / word throughout the text and highlighting them, and staying persistent. I find this very useful for highlighting all major character names, as well as calling attention to filler words, but I have not found a good solution for this. I’m also a fairly new Scrivener user, so forgive me if this is a simple fix.


You could use styles to set different highlights for each character. See the PDF attached, especially the twelfth page (numbered 400).

You might also get some use out of Edit > Writing Tools > Linguistic Focus (though this doesn’t pick out proper nouns in isolation).

Someone else might have a better idea.

Styles.pdf (440 KB)

I really like this new conditional formatting tool! The Styles function also seems to be a step in the right direction, but I couldn’t exactly find anything in the document about how to automatically apply styles based on the content of the writing. Maybe I’m missing something in the document? I do see your highlighted bit, about using a separate style for each character and using the highlighting function to call out character names. Is there a way to do this automatically?

AFAIK you can’t automatically apply a style based on content, I’m afraid. You would have to apply them manually.

You could create a style, give it a short cut, then search through the project for a name and apply the style to each occurrence before going to the next, but it would be boring and fiddly.

As brookter says, this appears to be a manual-only task.

Would be simple if we could search for all mentions of Blobby and replace them with CMD2BlobbyCMD2, where CMD2 was our shortcut for Blobby’s highlight colour, but that doesn’t appear to be possible.

Would also be good if we could create an automatic text replacement to replace every typed Blobby with CMD2BlobbyCMD2 (to save us having to type the shortcut), but, again, that doesn’t appear to work.

Easier to do with a new project where the shortcuts are used while writing, but laborious (though not impossible) to work though an existing project of tens of thousands of words.

Would also be nice if we could just search and replace by formatting, replacing [black-text] Blobby with [red-text] Blobby, but that also seems to be impossible.

We could search for Blobby and replace with Blobby, compile to RTF (so we get all the references to Blobby in red font), and then import that RTF back into Scrivener, but that would also be a fudge. On a really long project, that might be faster than making each change manually, especially if there are lots of names to code with different colours.

Someone else might have better ideas.

EDIT: We could also use SPAN or MARK to search and replace Blobby with a highlight colour, compile to .docx, and then import back into Scrivener. Another inelegant fudge.

<span style="background-color:#00FF00">Blobby</span>
<mark style="background-color:#F08080">Blobby</mark>

I like that idea Bridey. I might do that when I start the editing and revising process. Is there a way to break a document back into folders and sections when importing from RTF or would you have to go chapter by chapter in order to get it to work?