Editing trees