I do not clearly understand your problem. Title() method works correctly for me.
The best way to recognize your problem is to create a descriptive test package demonstrating it. Then pack it and attach the file on this forum. We will see what is going wrong.