resize max_size window, re-arrange the order of some gui elements