I have a listView with custom objects defined by the xml-layout below. I want the textView with id "info" to be ellipsized on a single line, and I've tried using the attributes

android:singleLine="true"android:ellipsize="end"

without success.


singleLine 被废弃了,可以使用:

android:lines="1"android:scrollHorizontally="true"

替换它。


参考:

Ellipsize not working for textView inside custom listView

更多相关文章

  1. android 进程自杀再重启的方法
  2. 一步步教你为网站开发Android客户端
  3. Android倒计时功能的实现
  4. android Immutable bitmap passed to Canvas constructor异常
  5. Android中替换ExpandableListView控件前面的箭头图标
  6. 去掉Button的默认背景
  7. ERROR: No installed build tools found. Install the Android(
  8. Android(安卓)DEX 方法超过64K限制
  9. android 颜色、 透明度参考表

随机推荐

  1. android 异步获取图片
  2. ADB连接Android设备的三种方法
  3. Android(安卓)Animation学习笔记
  4. Android(安卓)应用程序之间数据共享—Con
  5. Android(安卓)ListView动画实现方法
  6. Chrome for Android(安卓)编译了两天终于
  7. 实战技巧:Android异步指南
  8. 8、Android中Intent(意图)
  9. android switch模块
  10. Android(安卓)获取远程图片与本地图片缓