TextAppearanceInfo.Builder | API reference | Android Developers
Summary: Ctors | Methods | Inherited Methods
public
static
final
class
TextAppearanceInfo.Builder
extends Object
Builder for TextAppearanceInfo.
Summary
Public constructors | |
|---|---|
Builder()
|
|
Public methods | |
|---|---|
TextAppearanceInfo
|
build()
Returns |
TextAppearanceInfo.Builder
|
setAllCaps(boolean allCaps)
Set whether the transformation method applied to the current editor is set to all caps. |
TextAppearanceInfo.Builder
|
setElegantTextHeight(boolean elegantTextHeight)
Set the elegant height metrics flag. |
TextAppearanceInfo.Builder
|
setFallbackLineSpacing(boolean fallbackLineSpacing)
Set whether to expand linespacing based on fallback fonts. |
TextAppearanceInfo.Builder
|
setFontFeatureSettings(String fontFeatureSettings)
Set the font feature settings. |
TextAppearanceInfo.Builder
|
setFontVariationSettings(String fontVariationSettings)
Set the font variation settings. |
TextAppearanceInfo.Builder
|
setHighlightTextColor(int highlightTextColor)
Set the color of the text selection highlight. |
TextAppearanceInfo.Builder
|
setHintTextColor(int hintTextColor)
Set the current color of the hint text. |
TextAppearanceInfo.Builder
|
setLetterSpacing(float letterSpacing)
Set the text letter-spacing, which determines the spacing between characters. |
TextAppearanceInfo.Builder
|
setLineBreakStyle(int lineBreakStyle)
Set the line-break strategies for text wrapping. |
TextAppearanceInfo.Builder
|
setLineBreakWordStyle(int lineBreakWordStyle)
Set the line-break word strategies for text wrapping. |
TextAppearanceInfo.Builder
|
setLinkTextColor(int linkTextColor)
Set the text color used to paint the links in the editor. |
TextAppearanceInfo.Builder
|
setShadowColor(int shadowColor)
Set the color of the text shadow. |
TextAppearanceInfo.Builder
|
setShadowDx(float shadowDx)
Set the horizontal offset (in pixels) of the text shadow. |
TextAppearanceInfo.Builder
|
setShadowDy(float shadowDy)
Set the vertical offset (in pixels) of the text shadow. |
TextAppearanceInfo.Builder
|
setShadowRadius(float shadowRadius)
Set the blur radius (in pixels) of the text shadow. |
TextAppearanceInfo.Builder
|
setSystemFontFamilyName(String systemFontFamilyName)
Set the system font family name if the |
TextAppearanceInfo.Builder
|
setTextColor(int textColor)
Set the current text color of the editor. |
TextAppearanceInfo.Builder
|
setTextFontWeight(int textFontWeight)
Set the weight of the text. |
TextAppearanceInfo.Builder
|
setTextLocales(LocaleList textLocales)
Set the |
TextAppearanceInfo.Builder
|
setTextScaleX(float textScaleX)
Set the extent by which text should be stretched horizontally. |
TextAppearanceInfo.Builder
|
setTextSize(float textSize)
Set the text size (in pixels) obtained from the current editor. |
TextAppearanceInfo.Builder
|
setTextStyle(int textStyle)
Set the style (normal, bold, italic, bold|italic) of the text. |
Inherited methods | |||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
From class
| |||||||||||||||||||||||
Public constructors
Builder
public Builder ()
Public methods
setElegantTextHeight
public TextAppearanceInfo.Builder setElegantTextHeight (boolean elegantTextHeight)
Set the elegant height metrics flag. This setting selects font variants that have not been compacted to fit Latin-based vertical metrics, and also increases top and bottom bounds to provide more space.
| Parameters | |
|---|---|
elegantTextHeight |
boolean |
| Returns | |
|---|---|
TextAppearanceInfo.Builder |
This value cannot be null. |
setFallbackLineSpacing
public TextAppearanceInfo.Builder setFallbackLineSpacing (boolean fallbackLineSpacing)
Set whether to expand linespacing based on fallback fonts.
| Parameters | |
|---|---|
fallbackLineSpacing |
boolean |
| Returns | |
|---|---|
TextAppearanceInfo.Builder |
This value cannot be null. |
setLetterSpacing
public TextAppearanceInfo.Builder setLetterSpacing (float letterSpacing)
Set the text letter-spacing, which determines the spacing between characters. The value is in 'EM' units. Normally, this value is 0.0.
| Parameters | |
|---|---|
letterSpacing |
float |
| Returns | |
|---|---|
TextAppearanceInfo.Builder |
This value cannot be null. |
setShadowRadius
public TextAppearanceInfo.Builder setShadowRadius (float shadowRadius)
Set the blur radius (in pixels) of the text shadow.
| Parameters | |
|---|---|
shadowRadius |
float: The units of this value are pixels. |
| Returns | |
|---|---|
TextAppearanceInfo.Builder |
This value cannot be null. |
setSystemFontFamilyName
public TextAppearanceInfo.Builder setSystemFontFamilyName (String systemFontFamilyName)
Set the system font family name if the Typeface of the text is created from a
system font family.
| Parameters | |
|---|---|
systemFontFamilyName |
String: This value may be null. |
| Returns | |
|---|---|
TextAppearanceInfo.Builder |
This value cannot be null. |
setTextSize
public TextAppearanceInfo.Builder setTextSize (float textSize)
Set the text size (in pixels) obtained from the current editor.
| Parameters | |
|---|---|
textSize |
float: The units of this value are pixels. |
| Returns | |
|---|---|
TextAppearanceInfo.Builder |
This value cannot be null. |