实线和虚线进度条控件 Android CircleProgressBar
- 授权协议: Apache 2.0
- 开发语言: Java
- 操作系统: Android
- 软件首页: https://github.com/dinuscxj/CircleProgressBar
- 软件文档: https://github.com/dinuscxj/CircleProgressBar/blob/master/README-ZH.md
- 官方下载: https://github.com/dinuscxj/CircleProgressBar/archive/master.zip
软件介绍
CircleProgressBar继承ProgressBar, 是包含实心和线条两种风格的圆环进度条. 此外, 进度值可以随意定制. 如果你对酷炫的进度条比较感兴趣, 或许你更喜欢 LoadingDrawable.
用法
Gradle
dependencies {
compile 'com.dinuscxj:circleprogressbar:1.0.0'
}用在xml中:
<com.dinuscxj.progressbar.CircleProgressBar android:id="@+id/line_progress" android:layout_marginTop="@dimen/default_margin" android:layout_width="50dp" android:layout_height="50dp" />
属性
有下面这些属性你可以设置:
The style:
solid
line
The progress text:
text color
text size
visibility
format
The progress circle:
width
color
background color
The line style:
width
count
例如:
<com.dinuscxj.progressbar.CircleProgressBar android:layout_width="50dp" android:layout_height="50dp" app:style="line" app:progress_text_color="@color/holo_purple" app:progress_text_size="@dimen/progress_text_size" app:draw_progress_text="true" app:progress_text_format_pattern="@string/progress_text_format_pattern" app:progress_stroke_width="1dp" app:progress_color="@color/holo_purple" app:progress_background_color="@color/holo_darker_gray" app:line_width="4dp" app:line_count="30"/>
优点
继承ProgressBar, 不必关心当前进度状态的保存, ProgressBar 已经在onSaveInstanceState()和 onRestoreInstanceState(Parcelable state)中帮我们写好了。
定制性很强,可以设置两种风格的进度条,设置进度条的颜色和进度文本的颜色和大小, 由于代码中对于进度文本的格化化是使用的String.format(), 所以进度文本可以根据需要随意定制
代码优雅,代码注释很全面,格式整齐,可以直接在xml中设置相关的属性。
深入理解计算机系统(英文版·第2版)
[美] Randal E. Bryant、[美] David R. O'Hallaron / 机械工业出版社 / 2011-1 / 128.00元
本书是一本将计算机软件和硬件理论结合讲述的经典教程,内容覆盖计算机导论、体系结构和处理器设计等多门课程。本书的最大优点是为程序员描述计算机系统的实现细节,通过描述程序是如何映射到系统上,以及程序是如何执行的,使读者更好地理解程序的行为为什么是这样的,以及造成效率低下的原因。 相对于第1版,本版主要是反映了过去十年间硬件技术和编译器的变化,具体更新如下: 1. 对系统的介绍(特别是实际使......一起来看看 《深入理解计算机系统(英文版·第2版)》 这本书的介绍吧!
