I have an action bar with a title. Another string is added dynamically to the action bar. I have tried using OnSizeChanged and addOnLayoutListener to resize the action bar title according to the length of the string added latter.The action bar title is resized properly most of the times.
The issue is whenever a shorter string is dynamically added after a longer string, the size of the title is not increased. The width of the title text view remains when a shorter string replaces longer string.