Skip to content
New issue

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

Library has a configurable stroke witdth for the idle and the progress state #72

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

diego-gomez-olvera
Copy link

It is convenient to be able to tune the stroke width when the button is shown as idle and when a progress indicator is shown.

@diego-gomez-olvera
Copy link
Author

The library supports right now custom properties, but they cannot be defined in a theme following this pattern (http://blog.stylingandroid.com/custom-controls-part-3/) due that it ignores the constructor parameter 'int defStyleAttr'. The commit 7a0725e fixes it.

@diego-gomez-olvera
Copy link
Author

It is normally known if the progress view is going to be determinate or not, so it is handy to have an XML attribute 'cpb_progressIndeterminate' to define it.

@diego-gomez-olvera
Copy link
Author

It is convenient to support the android attribute text as default for 'cpb_textIdle', as well as support CharSequence given the fact that TextView class hierarchy support it.

@hojatdelfan
Copy link

thanks

return mIdleText;
}

public String getCompleteText() {
public CharSequence getCompleteText() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please help me. what's wrong with String ?

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CharSequence is more flexible.

E.g. https://developer.android.com/reference/android/text/Spannable implements CharSequence interface, so you can make text with different color, size, style, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants