码迷,mamicode.com
首页 > 移动开发 > 详细

Android TextView 跑马灯效果

时间:2015-09-17 11:48:34      阅读:142      评论:0      收藏:0      [点我收藏+]

标签:

  文本跑马灯必须设置的几个文本属性:

    android:marqueeRepeatLimit="marquee_forever"     设置跑马灯的次数:永久
            android:ellipsize="marquee"             跑马灯方式 
            android:focusable="true"              获取焦点
            android:singleLine="true"              单行
            android:focusableInTouchMode="true"      可以通过touch来获得focus
        文本的宽度可以任意设置,如:固定宽,wrap_conent ,fill_parent           ,当字体的宽度大于设置的容纳宽度,则会“走起来”

Android TextView 跑马灯效果

标签:

原文地址:http://www.cnblogs.com/hanhua/p/4815646.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!