Android TextView 沉没效果: Titanic

ybw8 9年前

Titanic 是一个 Android 实验,显示的是 TextView 的下沉效果。

Android TextView 沉没效果: Titanic

How to use

Add aTitanicTextViewto your layout:

<com.romainpiel.titanic.TitanicTextView      android:id="@+id/titanic_tv"      android:text="@string/loading"      android:layout_width="wrap_content"      android:layout_height="wrap_content"      android:textColor="#212121"      android:textSize="70sp"/>

To start the animation:

titanic = new Titanic();  titanic.start(myTitanicTextView);

You may want to keep track of the titanic instance after the animation is started if you want to stop it.

To stop it:

titanic.cancel();

项目主页:http://www.open-open.com/lib/view/home/1433400397322