Sections mysteriously highlighted in white

Hi there,

In the past few days, I’ve started experiencing this very annoying bug. I tend to highlight key phrases/passages in green or pink or yellow in every scene. I’ve been doing this for awhile, but since sometime last week, when I close out Scrivener and reopen it, I find that in between the passages I’ve highlighted, all the rest of the text is now highlighted in white.

For one thing, I never highlight anything in white (I know it’s white because ages ago I customised my editor’s background to a beige colour). I can select all these sections and delete the highlight, and it returns to my normal background colour. But when I close out Scrivener and go back in again, the mysteriously-highlighted sections are back.

This was sporadic last week; it might only affect certain scenes. As of today, every single scene that has highlighting in it is surrounded by white highlighting, that either fills the space between two sections I highlighted, or it highlights in white through to the end of the text, or on some cases, just a few paragraphs afterwards.

It’s completely random-seeming. I’ve had no crashes, no crash reports. I’m using the latest version, 2.8, for Mac OS Sierra, which I upgraded to last week – so I’m immediately suspicious that Sierra has something to do with this.

I can reproduce this at will now, since as of today, every single scene in all of my manuscripts with highlighting in it has been filled with white highlighting in random spots.

Please let me know if any other information is necessary to help figure this out. Thanks.

** Additionally: This might sound crazy but the white highlighting everywhere is driving me nuts, so as a temporary workaround, I’ve found that if I highlight the sections that have gone white the beige color of my background, then close out and reopen, they stay that same beige colour. They’re actually highlighted, but at least they’re not driving me nuts. This is not a solution, but it’s all I can figure out to do.

I’ve looked at my console and see a few errors but they don’t appear to have anything to do with Scrivener. Under “Process,” it labels them as parsecd, mdworker, Google Photos Backup, and suggestd. None of that means anything to me, admittedly!

This may have already been mentioned elsewhere, but for me, it’s not just highlights against a custom editor background that are causing blocks of text to be highlighted white.

Now I’ve found that comments turn dark brown – both the comment in “comments & footnotes” section, and the bit of text I’ve selected. They’re so dark that I can barely read them, and I can’t find any way to change this color whatsoever.

I’ve tried returning my editor background to the default white, but this doesn’t make any difference. The problems are still occurring.

Besides downgrading the OS, which is a monstrous hassle for me at this point, are there any other possibilities? I’ve tried to look but I can’t see any proof that this is something Apple is concerned with for future fixes, but fingers are crossed.

Screen Shot 2016-11-03 at 12.51.47 pm.png

Hi,

This is one of the many, many bugs Apple introduced in macOS Sierra. What is happening is this:

Apple’s text engine has always used a somewhat unconventional way of turning off highlights in RTF. The RTF should look something like this:

Some {\cb2 highlighted} text.

(“cb2” says: "use the second colour in the colour table for the background of this text.)

Apple’s RTF does this:

Some \cb2 highlighted \cb1 text.

“cb1” refers to the first colour in the RTF file’s colour table, which is always white. So, Apple’s RTF essentially says, “Highlight this text yellow, and then text after it white,” rather than, “Highlight this text yellow, then turn highlights off.”

Apple’s code has always done this and it’s never been a problem, because the convention in most apps - including Apple’s text system - has always been to treat white highlights as no highlights at all. So, any white highlights in an RTF file are generally ignored.

This is not the case in Sierra, however. In Sierra, utterly bizarrely, this is happening:

  1. Apple’s code is still using the old convention when writing RTF files. So, when writing an RTF file, Apple’s code still uses white highlights to turn highlights off.

  2. Apple’s code for reading RTF files, however, no longer ignores white highlights - it applies white highlights to the text. This means that if you have a coloured editor background (you won’t notice the problem if you have a white editor background, of course) and add a highlight somewhere in your text, when you save, close and reopen the document, all text after that highlight will be highlighted white.

I have found a workaround for this in the next update to Scrivener: I strip white highlights in my own code after loading an RTF file.

It’s a pretty silly bug, but don’t get me started on Sierra… What seemed like a minor update introduced loads of new bugs, such as broken line spacing after line breaks, graphical lags when hitting return between paragraphs, and many more. I spent a good couple of weeks just finding workarounds to Sierra bugs. :imp:

Anyway, I hope that explains the problem - there is a fix in the works, as I say.

Thanks and all the best,
Keith

Thanks for such a thorough reply and explanation!

I knew I should’ve listened to my gut when my husband upgraded to Sierra (as he always does, immediately after an update). In the future I think I’ll be more prone to hanging back. I appreciate all your work, and how frustrating this must be!