如何在行标题中显示任何文本数据(姓名、城市等)?默认情况下,它只显示和适合1-3个数字字符,但当您尝试将数字更改为单词时,行标题不会更改其大小,而只显示该单词的一部分。
附言:我们谈论的是安卓库TableView
发布于 2020-02-15 06:28:59
如您所见,在the Sample app中,Row Header有一个内容wıDTH值;
<RelativeLayout android:id="@+id/root"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:background="@color/cell_background_color"
android:layout_width="@dimen/row_header_width"
android:layout_height="@dimen/cell_height">所以,为了达到你想要的效果,你需要改变常量row_header_width的值,或者你可以使用下面的代码设置行头宽度大小;
tableView.setRowHeaderWidth(int rowHeaderWidth)https://stackoverflow.com/questions/60198264
复制相似问题