@@ -58,15 +58,27 @@ cb_image_scale_type - {center, center_inside, center_crop, fit_center, fit_start
58
58
cb_image_weight - {format - integer} </p >
59
59
<h3 > Java Code </h3 >
60
60
``` java
61
+ CustomButton(Context context, LayoutParams layoutParams, int backgroundColor, int textColor, Drawable icon)
61
62
setShapeBackground(int shapeType, int shapeRadius)
62
63
setBackgroundColorStateList(ColorStateList colorStateList)
64
+ setBackgroundColor(int color)
65
+ setBackgroundColorNormal(int color)
66
+ setBackgroundColorPressed(int color)
67
+ setBackgroundColorDosabled(int color)
63
68
setFrame(int color, float size)
64
69
setFrame(ColorStateList colorStateList, float size)
70
+ setFrameColor(int color)
71
+ setFrameColorNormal(int color)
72
+ setFrameColorPressed(int color)
73
+ setFrameColorDisabled(int color)
65
74
setFrameSize(float frameSize)
66
75
removeFrame()
76
+ setText(String text)
67
77
setTextColor(int color)
78
+ setTextColorNormal(int color)
79
+ setTextColorPressed(int color)
80
+ setTextColorDisabled(int color)
68
81
setTextColor(ColorStateList colorStateList)
69
- setText(String text)
70
82
setTextSize(float size)
71
83
setTextPadding(int [] padding) - int [4 ]{CustomButton . LEFT , CustomButton . TOP , CustomButton . RIGHT , CustomButton . BOTTOM }
72
84
setTextParams(int weight, int [] padding)
@@ -76,4 +88,8 @@ setElevationEnabled(boolean enabled)
76
88
and evry XML tag have getter
77
89
```
78
90
<h3 > Static field </h3 >
79
- LEFT, TOP, RIGHT, BOTTOM
91
+ LEFT, TOP, RIGHT, BOTTOM - for image position
92
+
93
+ <h2 > Dependencies </h2 >
94
+ In demo application <a href =" https://github.com/yukuku/ambilwarna " > Ambil Warna Library</a > was used.
95
+
0 commit comments