move whitespace from bottom to head in mainloop