Still have no idea what was causing the Rectangle name clash with (WinAPI?). Renamed the stupid thing and gave up.