Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to force a syntax-highlighting refresh in emacs?

In emacs, especially when ssh'ed into a remote machine, there's a delay between when I type a closing quotation mark and when emacs updates the syntax-highlighting to reflect that change. For a few seconds, all of the text after my quotation is highlighted as if it were part of the quotation. Usually this is fine, but sometimes I'd rather not wait. Is there a way to tell emacs to "re-highlight everything right now"?

like image 411
davidreedernst Avatar asked Apr 12 '11 03:04

davidreedernst


1 Answers

Yes. The emacs command is M-x font-lock-fontify-buffer if I recall it right. You can bind it to a key sequence if it's not already bound in your mode.

like image 115
Antti Huima Avatar answered Sep 30 '22 16:09

Antti Huima