github干货分享之1
相信很多人对余额宝的数字跳动印象很深吧,余额数字蹭蹭蹭往上涨,但这样的效果难免让人有审美疲劳.
下面推荐一款github star数过千的数字控件,动画过渡平滑,适合金钱、温度、速度等数字控件展示。
使用也很方便:
Getting started
Add the ticker dependency to your build.gradle
.
compile 'com.robinhood.ticker:ticker:1.1.1'
Usage
Define the TickerView
in XML:
<com.robinhood.ticker.TickerView android:id="@+id/tickerView"
Then add the character array to specify the animation style:
final TickerView tickerView = findViewById(R.id.tickerView);
That's it! Now you can call setText
to display your data.
github地址:https://github.com/robinhood/ticker
关注头条号【胖博士】,更多互联网干货和原创科技文章推送!