Exporting to PDF Highlights Words
When I export my MD documents to PDF a few "random" words in the PDF are highlighted yellow (acronyms or abbreviations with variable case seem to trigger this). At first, I thought it was because I had grammar and spelling checks switched on but I've switched those settingsl off and the highlighting still happens. The words do not appear highlighted in app, just in the output. Does anyone else have this? Is there a setting I'm not seeing so that no extra markup get's carried over to the final document?
Comments are currently closed for this discussion. You can start a new one.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
Support Staff 1 Posted by Brett on 23 Sep, 2020 04:25 PM
Could you attach a document that causes the issue for testing purposes? Also let me know which Style you're using.
- Brett
2 Posted by phi.fibonacci on 23 Sep, 2020 07:05 PM
Ok... so when you asked me for a test file (test.md) I took an excerpt from one of my documents with the problems. I checked to make sure it was displaying the same behavior. It did not (the original PDF was clean).! I then turned on spell check and exported a second time (resulting file is test.pdf). The highlight is present. I turned off spell check and exported a third time (resulting file is test2.pdf). The highlight was still present. So... it seems that on the initial export (if spell check is off) everything comes out clean. On all subsequent exports I get the highlighting. If needed, I can put together a screen recording demonstrating.
3 Posted by phi.fibonacci on 23 Sep, 2020 07:41 PM
I created a quick screen recording demoing the behavior.
Support Staff 4 Posted by Brett on 24 Sep, 2020 01:54 PM
Ok, this is happening because Marked uses the
<mark>
tag for highlighting errors in the preview, and then isn't removing that tag when generating the PDF. This is due to a relatively recent change, but I'm surprised it hasn't been reported before.I've fixed it for the next update. In the meantime, you can correct the behavior using Preferences->Style->Additional CSS. Insert (or add) the following:
Thanks,
Brett
5 Posted by phi.fibonacci on 24 Sep, 2020 04:22 PM
Glad I was able to bring to your attention. Thank you so much for the prompt response!
Take care.
Brett closed this discussion on 25 Sep, 2020 04:16 PM.