20150618_Andriod_设置TextView垂直滚动
布局文件
android:scrollbars="vertical"
android:singleLine="false"
代码文件
ctl_tv_content.setMovementMethod(ScrollingMovementMethod.getInstance());
******************************
example:
<TextView
android:id="@+id/tvResult"
android:layout_width="280dp"
android:layout_height="260dp"
android:layout_below="@+id/editText_f8_number"
android:layout_centerHorizontal="true"
android:gravity="left"
android:height="260dp"
android:scrollbars="vertical"
android:singleLine="false"
android:textSize="14sp" />
///////////////
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_f8__ws);
initView();
tv_result.setMovementMethod(ScrollingMovementMethod.getInstance());
}
******************************