[안드로이드] 진행률을 나타내는 원형 계량기 뷰를 공개했습니다.
6590 단어 Android
2019/11/5 창고가 사라져서 조만간 다시 쓸 거예요.
안녕하세요. 저는 사과 로고의 마야히로를 특히 좋아해요.
나는 애플의 로고를 특히 좋아하지만, 왜 나의 위치는 안드로이드 응용 엔지니어인지 모르겠다.
그럼 이번Studyplus의Android 애플리케이션원형규격View공개한다를 사용하기로 했습니다.
https://github.com/studyplus/GaugeSampleApplication
특징.
1. 원형 게이지를 쉽게 표시할 수 있다.( GaugeView.java )
단색 디스플레이
그래디언트 디스플레이
디스플레이 중단 제한



※ 한시적 돌파: 개인이 100% 이상 칭하는 상태
2. 리스트 표시에 사용되는 간단한 디자인도 준비했다.( SimpleGaugeView.java )
단색 디스플레이
그래디언트 디스플레이
디스플레이 중단 제한



3. 당연히 애니메이션을 할 줄 안다.
흑백 애니메이션
다색 애니메이션
극한 애니메이션



※ 간단한 디자인은 아니다.
※ 클릭하여 애니메이션을 여러 번 감상할 수 있습니다.
사용법
레이아웃에 적당히 올려주세요.
<com.mayahiro.gaugesampleapplication.GaugeView
android:id="@+id/gauge1"
android:layout_width="match_parent"
android:layout_height="300dp"
android:layout_margin="16dp" />
<com.mayahiro.gaugesampleapplication.SimpleGaugeView
android:id="@+id/simple_gauge1"
android:layout_width="match_parent"
android:layout_height="300dp"
android:layout_margin="16dp" />
적절한 데이터 설정
GaugeView gauge1View = (GaugeView) findViewById(R.id.gauge1);
gauge1View.setData(90, "%", ContextCompat.getColor(this, R.color.color_90), 90, true);
SimpleGaugeView simpleGauge1View = (SimpleGaugeView) findViewById(R.id.simple_gauge1);
simpleGauge1View.setData(90, "%", ContextCompat.getColor(this, R.color.color_90));
최후
하나의 파일을 쉽게 사용할 수 있기 때문에 진도율을 표시하려면 반드시 사용하십시오.
의견, 소감, Issue, Pull request 등을 기대합니다.
Reference
이 문제에 관하여([안드로이드] 진행률을 나타내는 원형 계량기 뷰를 공개했습니다.), 우리는 이곳에서 더 많은 자료를 발견하고 링크를 클릭하여 보았다 https://qiita.com/mayahiro/items/4c4bb05495d4d5caf8b0텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
우수한 개발자 콘텐츠 발견에 전념
(Collection and Share based on the CC Protocol.)