Interface DynamicTextWidget
- All Superinterfaces:
BaseWidget
,DynamicWidget
- All Known Implementing Classes:
DynamicBottomAppBar
,DynamicBottomNavigationView
,DynamicNavigationRailView
,DynamicTabLayout
,DynamicToolbar
Interface to create dynamic widgets with a text view which can be tinted according to the
DynamicTheme
.-
Method Summary
Modifier and TypeMethodDescriptionint
Returns the value of text color applied to this widget.int
getTextColor
(boolean resolve) Returns the value of text color applied to this widget.int
Returns the text color type applied to this widget.void
Set text color for this widget according to the supplied values.void
setTextColor
(int textColor) Set the value of text color for this widget.void
setTextColorType
(int textColorType) Set the text color type to this widget.void
setTextWidgetColor
(boolean setTextColor) Set color and text color for this widget at once.Methods inherited from interface com.pranavpandey.android.dynamic.support.widget.base.BaseWidget
initialize, loadFromAttributes
Methods inherited from interface com.pranavpandey.android.dynamic.support.widget.base.DynamicWidget
getBackgroundAware, getColor, getColor, getColorType, getContrast, getContrast, getContrastRatio, getContrastWithColor, getContrastWithColorType, isBackgroundAware, setBackgroundAware, setColor, setColor, setColorType, setContrast, setContrastWithColor, setContrastWithColorType, setEnabled
-
Method Details
-
getTextColorType
int getTextColorType()Returns the text color type applied to this widget.- Returns:
- The text color type applied to this widget.
- See Also:
-
setTextColorType
void setTextColorType(int textColorType) Set the text color type to this widget.- Parameters:
textColorType
- Text color type for this widget.- See Also:
-
getTextColor
Returns the value of text color applied to this widget.- Parameters:
resolve
-true
to resolve the text color applied to this widget.- Returns:
- The value of text color applied to this widget.
-
getTextColor
Returns the value of text color applied to this widget.- Returns:
- The value of text color applied to this widget.
-
setTextColor
Set the value of text color for this widget.- Parameters:
textColor
- Text color for this widget.
-
setTextColor
void setTextColor()Set text color for this widget according to the supplied values.Generally, it should be a tint color so that text will be visible on this widget background.
-
setTextWidgetColor
void setTextWidgetColor(boolean setTextColor) Set color and text color for this widget at once.- Parameters:
setTextColor
-true
to set the text color also.
-