I want to use different color-theme for different file types. I tried to use add-hook to set the color-theme for the major-mode, but it only applies when the buffer is first load. If I switch to another buffer and switch back, the color-theme will stay the same as it is in the previous buffer. Then I tried to set the window-configuration-change-hook, but the window blinks every time I press C-x, or M-x, or whatever that change the window properties.

Is there a better way to set the color-theme for each buffer?

1 Answer 1


If you happen to be using emacs 24, color-theme-buffer-local in the package manager will do what you want.

The version here reportedly works with 23.

You must log in to answer this question.

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