Is there are set of guidelines for the Android how the text should be truncated in the controls? Fading text, ellipsis, cut in the middle, etc.?
User Experience Stack Exchange is a question and answer site for user experience researchers and experts. It only takes a minute to sign up.Sign up to join this community
A quick check of developer.android.com shows that the standard approach to stop text wrapping over lines is to go with your second option: to display with ellipses.
android:ellipsize=causes words in the text that are longer than the view is wide to be ellipsized instead of broken in the middle
However; considering this is UX.StackExchange and this isn't really the place to come for coding guidelines, there are some specific usability issues to consider when thinking of truncating your text in any fashion. Just because you technically can implement techniques to show that more text exists, doesn't mean that it's the best way to do things.
For instance; as stated in the Windows User Experience Interaction Guidelines:
Avoid truncated text and their associated ellipses. Users should never have to interact with a window to view its typical content — reserve resizing and scrolling for unusually large content.
Yes, it's Microsoft and the guideline is for Windows 7 / Vista, but the reasoning is sound. Also, don't forget that ellipses have other connotations, particularly if you're going to be using them on the options you show above; ellipses on button.
For example, this image of a typical button shows ellipses:
Now in this instance the ellipses do not mean 'the label doesn't fit on the button' it actually means 'click this button to open up a new menu'.
So yes, you can go ahead and use the ellipses for the android options you have above as Android does cater for that option, but in reality if you find that your text / labels are too long for the controls they are used on then you either have the wrong controls or your text is too long. Don't look for workarounds to shoehorn your content into a layout, ensure that you design the layout and labels to fit correctly into the screen in the first place.
Also, if you are interested in truncation itself then there are also some good answers on this ux.se question about what type of truncation is preferable: Studies or experience on using faded text to indicate more content?
final int actionBarTitle = getResources().getSystem().getIdentifier("action_bar_title", "id", "android");
final TextView title = (TextView)getWindow().findViewById(actionBarTitle);