A circular android ProgressBar library which extends View, and the usage same as ProgressBar, It has solid,line and solid_line three styles. Besides, progress
A circular android ProgressBar library which extends View, and the usage same as ProgressBar, It has solid,line and solid_line three styles. Besides, progress
The CircleProgressBar extends View, It has both solid and line two styles. Besides, progress value can be freely customized. If you are interested in cool loading animations, you can see LoadingDrawable.
dependencies {
compile 'io.github.dinuscxj:circleprogressbar:1.4.1'
}There are several attributes you can set:
The progress style:
The progress text:
The progress circle:
The progress shader
The progress blur (blur radius must larger than zero)
The progress stroke cap
The line style:
for example : In the xml
format progress
private static final class MyProgressFormatter implements ProgressFormatter {
private static final String DEFAULT_PATTERN = "%d%%";
@Override
public CharSequence format(int progress, int max) {
return String.format(DEFAULT_PATTERN, (int) ((float) progress / (float) max * 100));
}
}
// set the ProgressFormatter as you want
CircleProgressBar.setProgressFormatter(new MyProgressFromatter);
// hide the progress
CircleProgressBar.setProgressFormatter(null);
I like Android, like open source, and like doing something interesting. :)
If you like CircleProgressBar or use it, you can star this repo and send me some feedback. Thanks! _
QQ Group: 342748245
Copyright 2015-2019 dinuscxj
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.No open issues yet, or sync has not completed.