made more linux compatible

- .csproj file v4 works in monodevelop
- ANSI.cs now reliably uses ANSI codec, not e.g. UTF8
- Program.cs uses the right directory on linux

Bug #1 doesn’t apply to me, but I tried compiling it from MonoDevelop.