zoukankan
html css js c++ java
propertyGrid实现选项(原创)
Draw Dorp-Down propertyGrid
[TypeConverter(
typeof
(backgroundRepeatConverter)),
DescriptionAttribute(
"
description
"
),
CategoryAttribute(
"
行为
"
)]
public
string
backgroundRepeat
{
get
{
if
(e.style.backgroundRepeat
==
null
)
return
""
;
return
e.style.backgroundRepeat;
}
set
{
e.style.backgroundRepeat
=
value;
}
}
public
class
backgroundRepeatConverter: StringConverter
{
public
override
StandardValuesCollection
GetStandardValues(ITypeDescriptorContext context)
{
return
new
StandardValuesCollection(
new
string
[]
{
"
repeat
"
,
"
repeat-x
"
,
"
repeat-y
"
,
"
no-repeat
"
}
);
}
public
override
bool
GetStandardValuesSupported(
ITypeDescriptorContext context)
{
return
true
;
}
public
override
bool
GetStandardValuesExclusive(
ITypeDescriptorContext context)
{
return
true
;
}
}
查看全文
相关阅读:
C#匿名类型
C#中实例Singleton
Unity Pitfall 汇总
Unity快捷键
System.Object
ExecuteInEditMode
preview放大镜
判断当前Selection是否为prefab
AddComponentMenu
MenuItem属性
原文地址:https://www.cnblogs.com/alice/p/189034.html
最新文章
Pass
glTexGen
UsePass & GrabPass
Texture Combiner
使用Windows绘图合成多张图
Color, Material, Lighting
UV mapping
Shaders
ShaderLab
视频显示设备
热门文章
可空类型
Property
GC类
GetHashCode()
DPI
C# Equals
C# ValueTypes
boxing & unboxing
C# params
C#隐式类型局部变量&隐式类型数组
Copyright © 2011-2022 走看看