make layout calculation easier
cleanup