Creates a window