Enclosing class:
TextAppearance


public static final class TextAppearance.Builder
extends java.lang.Object
Builds a TextAppearance.

Constructor Summary

Constructors
Constructor and Description
Builder()
Creates a new TextAppearance.Builder for constructing a TextAppearance

Method Summary

All Methods
Instance Methods
Concrete Methods
Modifier and TypeMethod and Description
TextAppearancebuild()
Constructs a TextAppearance with the specified appearance values.
TextAppearance.BuildersetFontFamilyName(java.lang.String fontFamilyName)
Returns TextView appearance configured with name of the font family.
TextAppearance.BuildersetFontStyle(int fontStyle)
Returns TextView appearance configured with style of the font.
TextAppearance.BuildersetTextColor(int textColor)
Returns TextView appearance configured with text color.
TextAppearance.BuildersetTextSize(float textSize)
Returns TextView appearance configured with text size.

Methods inherited from class java.lang.Object

equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

Builder

public Builder()
Creates a new TextAppearance.Builder for constructing a TextAppearance

Method Detail

build

@NonNull
public TextAppearance build()
Constructs a TextAppearance with the specified appearance values.
Returns:
TextAppearance.

setTextColor

@NonNull
public TextAppearance.Builder setTextColor(int textColor)
Returns TextView appearance configured with text color.
Parameters:
textColor - TextView text color.
Returns:
TextAppearance.Builder with the specified text color.

setTextSize

@NonNull
public TextAppearance.Builder setTextSize(float textSize)
Returns TextView appearance configured with text size.
Parameters:
textSize - TextView text size.
Returns:
TextAppearance.Builder with the specified text size.

setFontFamilyName

@NonNull
public TextAppearance.Builder setFontFamilyName(@Nullable
                                                         java.lang.String fontFamilyName)
Returns TextView appearance configured with name of the font family.
Parameters:
fontFamilyName - The name of the font family. May be null.
Returns:
TextAppearance.Builder with the specified text font.

setFontStyle

public TextAppearance.Builder setFontStyle(int fontStyle)
Returns TextView appearance configured with style of the font.
Parameters:
fontStyle - The style (normal, bold, italic) of the font.
Returns:
TextAppearance.Builder with the specified text font.