The exact same thing happened to me when I first started developing the built-in codearea to my GUI editor (Max'd GUI) - still, I did manage to fix it in the end.
I can't seem to figure out how to fix it. I've tried highlighting it by line but it seems slower than highlighting it by character.