fixed off-screen bug