如何在android中实现一个Material Design圆形进度条 [英] How to implement a material design circular progress bar in android

查看:32
本文介绍了如何在android中实现一个Material Design圆形进度条的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想制作一个 Material Design 圆形进度条,就像 Inbox by Gmail android 应用程序中的进度条一样.我如何实现这一点(在棒棒糖之前的设备中)?

I want to make a material design circular progress bar like the one in Inbox by Gmail android app. How do I achieve this (in pre-lollipop devices)?

我正在尝试实现类似的效果.Inbox by Gmail Material Design 循环进度条

Am trying to achieve a similar effect like this. Inbox by Gmail material design circular progress bar

推荐答案

更新

截至 2019 年,这可以使用 ProgressIndicator 轻松实现,在 Material Components 库 中,与 Widget.MaterialComponents.ProgressIndicator.Circular.Indeterminate 一起使用代码>样式.

As of 2019 this can be easily achieved using ProgressIndicator, in Material Components library, used with the Widget.MaterialComponents.ProgressIndicator.Circular.Indeterminate style.

更多详情请查看Gabriele Mariotti 的回答如下.

旧实现

这是 Material Design 圆形中间进度条的一个很棒的实现 https://gist.github.com/castorflex/4e46a9dc2c3a4245a28e.该实现仅缺乏通过 android 应用程序在收件箱中添加各种颜色的能力,但这做得非常好.

Here is an awesome implementation of the material design circular intermediate progress bar https://gist.github.com/castorflex/4e46a9dc2c3a4245a28e. The implementation only lacks the ability add various colors like in inbox by android app but this does a pretty great job.

这篇关于如何在android中实现一个Material Design圆形进度条的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆