Tree layout boilerplate