Class TextAppearance.Builder
- java.lang.Object
-
- com.yandex.mobile.ads.nativeads.template.appearance.TextAppearance.Builder
-
- Enclosing class:
- TextAppearance
public static final class TextAppearance.Builder extends java.lang.ObjectBuilds aTextAppearance.
-
-
Constructor Summary
Constructors Constructor Description Builder()Creates a newTextAppearance.Builderfor constructing aTextAppearance
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TextAppearancebuild()Constructs aTextAppearancewith 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.
-
-
-
Constructor Detail
-
Builder
public Builder()
Creates a newTextAppearance.Builderfor constructing aTextAppearance
-
-
Method Detail
-
build
@NonNull public TextAppearance build()
Constructs aTextAppearancewith 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.
-
-