Add proper open and copy method to Windows UI
Replace getonechar with raw_input(...)[0]

This solves the problem that Enter always stays in buffer
in Windows.
pep8ify