View.SaveAttributeDataForStyleable 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
存储有关属性的调试信息。
[Android.Runtime.Register("saveAttributeDataForStyleable", "(Landroid/content/Context;[ILandroid/util/AttributeSet;Landroid/content/res/TypedArray;II)V", "", ApiSince=29)]
public void SaveAttributeDataForStyleable(Android.Content.Context context, int[] styleable, Android.Util.IAttributeSet? attrs, Android.Content.Res.TypedArray t, int defStyleAttr, int defStyleRes);
[<Android.Runtime.Register("saveAttributeDataForStyleable", "(Landroid/content/Context;[ILandroid/util/AttributeSet;Landroid/content/res/TypedArray;II)V", "", ApiSince=29)>]
member this.SaveAttributeDataForStyleable : Android.Content.Context * int[] * Android.Util.IAttributeSet * Android.Content.Res.TypedArray * int * int -> unit
参数
- context
- Context
创建此视图的上下文。
- styleable
- Int32[]
对可样式数组 R.styleable.Foo 的引用
- attrs
- IAttributeSet
用于构造此视图的 AttributeSet。
TypedArray已由调用Resources#obtainAttributes(AttributeSet, int[])返回的解析 。
- defStyleAttr
- Int32
传递到视图构造函数的默认样式属性。
- defStyleRes
- Int32
传递到视图构造函数的默认样式资源。
- 属性
注解
存储有关属性的调试信息。 这应该由每个使用自定义样式的自定义自定义 View 在构造函数中调用。 如果自定义视图不调用它,则此视图使用的自定义属性在布局检查工具中不可见。
本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。