android-singleline

Is the xml attribute singleLine deprecated or not in Android?

泪湿孤枕 提交于 2019-11-28 05:11:17
singleLine is/was used in xml layout files for TextView and EditText something like the following: <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:singleLine="true" /> Some people on SO say singleLine is deprecated, while other people still suggest using it. Sometimes it even seems necessary to use when maxLines="1" doesn't work. (see here , here , and here ) The docs should be the place to go to answer this question, right? Here, they say: This constant was deprecated in API level 3. This attribute is deprecated. Use maxLines instead to change the

Is the xml attribute singleLine deprecated or not in Android?

Deadly 提交于 2019-11-27 00:49:46
问题 singleLine is/was used in xml layout files for TextView and EditText something like the following: <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:singleLine="true" /> Some people on SO say singleLine is deprecated, while other people still suggest using it. Sometimes it even seems necessary to use when maxLines="1" doesn't work. (see here, here, and here) The docs should be the place to go to answer this question, right? Here, they say: This