Android 太多的单词会使单词从屏幕上消失

Android 太多的单词会使单词从屏幕上消失,android,user-interface,interface,Android,User Interface,Interface,如果我写了太多的单词,说明2。这个词将出现在屏幕外。如何修复它 这是我的XML代码之一,我正在使用带有TextView的表布局 <TableRow android:layout_width="282dp"> <TextView android:layout_width="match_parent" android:layout_height="

如果我写了太多的单词,说明2。这个词将出现在屏幕外。如何修复它

这是我的XML代码之一,我正在使用带有TextView的表布局

<TableRow android:layout_width="282dp">
                    <TextView
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:text="Description2:"
                        android:textColor="#000"
                        android:textSize="20sp"
                        android:textStyle="bold" />
                    <TextView
                        android:id="@+id/txtDescription2"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:text="Description2 Here"
                        android:textColor="#000"
                        android:textSize="20sp"/>
                </TableRow>

有没有办法让它一直显示在描述的底部2?提前感谢…

您想要多行的长文本吗? 您可以使用此选项

安卓:布局重量

并在java代码中选择此文本视图。因为这是一种专注的工作

TextView text = (TextView)findViewById(R.id.text);
text.setSelected(true);
它以单行显示所有文本。文本移动缓慢。 此解决方案,文本长度不会改变用户界面。

可能的重复
android:singleLine="true"
android:ellipsize="marquee"
TextView text = (TextView)findViewById(R.id.text);
text.setSelected(true);