yah,its strange, although mmm-mode works with some bugs(indent and font-lock incorrectly etc) but it really change major mode when move between different chunks,and linum just work well.
i think there's not only one hook make linum update lineumber, because,after i comment out
(add-hook 'change-major-mode-hook 'linum-delete-overlays nil t)
it also make a little change with linenumber,it display wrong line number first time to enter a different chunk, and works well after that.
you can test it with:
1.comment out the line above;
2.turn on global-linum-mode;
3.edit a mixed file ,like php+html,
and move the cursor form html chunk to php chunk, you'll see what happend.
my English is not well, hope you can understand what i mean :)
yah,its strange, although mmm-mode works with some bugs(indent and font-lock incorrectly etc) but it really change major mode when move between different chunks,and linum just work well. major-mode- hook 'linum- delete- overlays nil t)
i think there's not only one hook make linum update lineumber, because,after i comment out
(add-hook 'change-
it also make a little change with linenumber,it display wrong line number first time to enter a different chunk, and works well after that.
you can test it with:
1.comment out the line above;
2.turn on global-linum-mode;
3.edit a mixed file ,like php+html,
and move the cursor form html chunk to php chunk, you'll see what happend.
my English is not well, hope you can understand what i mean :)