我已经成功地实现了这个进度条:
![enter image description here](https://istack.dev59.com/L4gly.webp)
使用类似下面这样的资源和animation-list:
![enter image description here](https://istack.dev59.com/HFmrz.webp)
![enter image description here](https://istack.dev59.com/3ERPU.webp)
![enter image description here](https://istack.dev59.com/8rZPD.webp)
但是问题是,我不能使用这些资源来实现半高度的进度条。
我曾尝试过类似下面这样竖直居中的半高度资源:
![enter image description here](https://istack.dev59.com/sn4CU.webp)
![enter image description here](https://istack.dev59.com/PTjcJ.webp)
![enter image description here](https://istack.dev59.com/xwy3u.webp)
但结果是:
![enter image description here](https://istack.dev59.com/M1eT3.webp)
Android 把这个进度条推到了底部。 有什么办法可以使我的半高度进度条居中吗?谢谢。
@Antoine Marques 我已经尝试过 Nine-patch drawable,但我得到的结果却像这样:
![enter image description here](https://istack.dev59.com/oilHK.webp)
这是我的 animation-list:
<item android:duration="200" android:drawable="@drawable/progressbar_indeterminate1_0" />
资源示例:
![这里输入图片描述](https://istack.dev59.com/aEzqi.webp)