Window creation and graphics device clearing