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?