android:persistentDrawingCache (Google官方译文)

Defines the persistence of the drawing cache. The drawing cache might be enabled by a ViewGroup for all its children in specific situations (for instance during a scrolling.) This property lets you persist the cache in memory after its initial usage. Persisting the cache consumes more memory but may prevent frequent garbage collection is the cache is created over and over again. By default the persistence is set to scrolling.

定义绘图的高速缓存的持久性。 绘图缓存可能由一个ViewGroup在特定情况下为其所有的子类启用,例如在一个滚动的过程中。 此属性可以在初次使用后保留在其在内存中的缓存。 坚持缓存会消耗更多的内存,但可能会阻止频繁的垃圾回收是反复创建缓存。 默认情况下持续存在设置为滚动。

Must be one or more (separated by '|') of the following constant values.

Xml文件中可以使用一下的值:

Constant Value Description
none 0x0 The drawing cache is not persisted after use.
animation 0x1 The drawing cache is persisted after a layout animation.
scrolling 0x2 The drawing cache is persisted after a scroll.
all 0x3 The drawing cache is always persisted.

更多相关文章

  1. 水平滚动条以及文字滚动
  2. Android-TextView多行本文滚动轻松实现
  3. android emulator( android模拟器)
  4. android实现TextView多行文本滚动
  5. android实现TextView多行文本滚动
  6. Android面试系列文章2018之Android部分WebView篇
  7. android 滚动条 相关属性
  8. 【Android】跑马灯效果(文字滚动)
  9. 【Android】滚动条属性

随机推荐

  1. MVC实现下拉框联动的实例详解
  2. C#怎么将 HTML转换为图片或 PDF?
  3. C#开发微信门户及应用(一)之微信接口的如
  4. Enum扩展特性实例代码
  5. C#中关于扩展方法的实例分析
  6. 详细介绍一个.net开源权限管理系统
  7. 总结一些编码和设计原则实例
  8. C#中如何格式化json字符串的方法分析
  9. ASP.NET Core 应用程序发布命令实例
  10. 分享在C#中时间戳是怎么转换的?