We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I was created a class extends class FancyButton like this : `public class BorderButton extends FancyButton {
public BorderButton(Context context) { super(context); changeThemeButton("#29a19c","#29a19c"); } public BorderButton(Context context, AttributeSet attrs) { super(context, attrs); changeThemeButton("#29a19c","#29a19c"); } private void changeThemeButton(String textColor, String borderColor){ int txtColor = Color.parseColor(textColor); int borColor = Color.parseColor(borderColor); setBorderWidth(2); setBorderColor(borColor); setTextColor(txtColor); setFocusBackgroundColor(borColor); // setRadius not work here because getHeight = 0 // setRadius(getHeight()/2); setBackgroundColor(ContextCompat.getColor(getContext(),android.R.color.transparent)); } @Override protected void onDraw(Canvas canvas) { super.onDraw(canvas); // setRadius worked but ripple effect gone setRadius(getHeight()/2); }
}` How can I set radius programmatically and keep ripple effect work ?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I was created a class extends class FancyButton like this :
`public class BorderButton extends FancyButton {
}`
How can I set radius programmatically and keep ripple effect work ?
The text was updated successfully, but these errors were encountered: