Enhancement for Editor

Is there a way to insert formatted source code for c++. It would be good for the #lighthack forum.

Is there a way to avoid the increasing line spacing after doing Enter?