Open a new window and write a text/plain document into it