I'm using emacs on a remote Linux server that I access via ssh.

I'm editing C files that have a non-standard suffix, so I have had to manually enter c-mode with M-x c-mode every time I open one of those files.

I found this to be annoying so I started monkeying with my .emacs to make that problem go away. This made all the color highlights in c-mode go away instead. Correction: All my color highlights are gone.

I've removed the .emacs file, logged out and logged back in, but now, the color highlights are gone.

I miss them! They were very helpful How do I get them back?

1 Answer 1


Ah ha -- my own annoyance and continued searching led to this. Add the following lines to your .emacs file:

(require 'font-lock)
(global-font-lock-mode t)

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .