Skip to content

Most visited

Recently visited

navigation

ActionLabel

public class ActionLabel
extends View

java.lang.Object
   ↳ android.view.View
     ↳ android.support.wearable.view.ActionLabel


ActionLabel is a specialized text display widget. An upper and lower bound for text size and a maximum number of lines are provided and the layout is adjusted automatically to find the largest possible text size satisfying those constraints.

In order to provide a fixed bound, an ActionLabel should always be used with a width and height of "match_parent" or a specific size. When created programmatically, you must supply a LayoutParams to do this:

 LayoutParams lp = new ViewGroup.LayoutParams(200, 50);
 parent.addView(label, lp);
 

Supported attributes are:

This site uses cookies to store your preferences for site-specific language and display options.

Hooray!

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.