pre modifying layout