height calculation edit