set title text correctly