notes: break set_display_notes() into smaller functions