Refactor find_next_line into select_view_line