settitle helper function