Fix various \r issues with windows

Also add a 2 in an error message (it's gSourceView2, not gSourceView).

This closes bugs 3150, 3151, 3152, and 3153.