(adjust_window_trailing_edge): New function.