I'm using vimwiki plugin with markdown. I'd like to highlight text using double equals, which isn't standard, but is quite useful. Ideally, this should replace background (for instance, yellow) and keep any other formatting, such as bold or italics.

Normal text. ==Highlighted text with **bold** and *italics*==. Normal text

Should be:

Highlighted text with bold and italics

  • 2
    The standard option is to define a syntax item for it (:help syntax, maybe?) and the highlight def link it to a group – D. Ben Knoble Oct 30 '20 at 22:34
  • what is the expected behavior when both bold and italic occurs like *italic with **bold** inside* « italic with bold inside » ? There is no bolditalic in Vim's highlight feature. – ewen-goisot Nov 2 '20 at 9:50
  • This is precisely one extra reason to try this "highlighting" solution: provided one text with italics inside, you can't simply surround it and make it bold, as it would lose visual formatting. – Ludenticus Nov 2 '20 at 15:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.