better window split, update tks function