/
iconoptions.go
172 lines (144 loc) · 4.48 KB
/
iconoptions.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
//----------------------------------------
// 代码由GenlibVcl工具自动生成。
// Copyright © ying32. All Rights Reserved.
//
//----------------------------------------
package vcl
import (
. "github.com/ying32/govcl/vcl/api"
. "github.com/ying32/govcl/vcl/types"
"unsafe"
)
type TIconOptions struct {
IObject
instance uintptr
// 特殊情况下使用,主要应对Go的GC问题,与VCL没有太多关系。
ptr unsafe.Pointer
}
// IconOptionsFromInst
// CN: 新建一个对象来自已经存在的对象实例指针。
// EN: Create a new object from an existing object instance pointer.
func IconOptionsFromInst(inst uintptr) *TIconOptions {
i := new(TIconOptions)
i.instance = inst
i.ptr = unsafe.Pointer(inst)
return i
}
// IconOptionsFromObj
// CN: 新建一个对象来自已经存在的对象实例。
// EN: Create a new object from an existing object instance.
func IconOptionsFromObj(obj IObject) *TIconOptions {
i := new(TIconOptions)
i.instance = CheckPtr(obj)
i.ptr = unsafe.Pointer(i.instance)
return i
}
// IconOptionsFromUnsafePointer
// CN: 新建一个对象来自不安全的地址。注意:使用此函数可能造成一些不明情况,慎用。
// EN: Create a new object from an unsecure address. Note: Using this function may cause some unclear situations and be used with caution..
func IconOptionsFromUnsafePointer(ptr unsafe.Pointer) *TIconOptions {
i := new(TIconOptions)
i.instance = uintptr(ptr)
i.ptr = ptr
return i
}
// Instance
// CN: 返回对象实例指针。
// EN: Return object instance pointer.
func (i *TIconOptions) Instance() uintptr {
return i.instance
}
// UnsafeAddr
// CN: 获取一个不安全的地址。
// EN: Get an unsafe address.
func (i *TIconOptions) UnsafeAddr() unsafe.Pointer {
return i.ptr
}
// IsValid
// CN: 检测地址是否为空。
// EN: Check if the address is empty.
func (i *TIconOptions) IsValid() bool {
return i.instance != 0
}
// TIconOptionsClass
// CN: 获取类信息指针。
// EN: Get class information pointer.
func TIconOptionsClass() TClass {
return IconOptions_StaticClassType()
}
// Assign
// CN: 复制一个对象,如果对象实现了此方法的话。
// EN: Copy an object, if the object implements this method.
func (i *TIconOptions) Assign(Source IObject) {
IconOptions_Assign(i.instance, CheckPtr(Source))
}
// GetNamePath
// CN: 获取类名路径。
// EN: Get the class name path.
func (i *TIconOptions) GetNamePath() string {
return IconOptions_GetNamePath(i.instance)
}
// DisposeOf
// CN: 丢弃当前对象。
// EN: Discard the current object.
func (i *TIconOptions) DisposeOf() {
IconOptions_DisposeOf(i.instance)
}
// ClassType
// CN: 获取类的类型信息。
// EN: Get class type information.
func (i *TIconOptions) ClassType() TClass {
return IconOptions_ClassType(i.instance)
}
// ClassName
// CN: 获取当前对象类名称。
// EN: Get the current object class name.
func (i *TIconOptions) ClassName() string {
return IconOptions_ClassName(i.instance)
}
// InstanceSize
// CN: 获取当前对象实例大小。
// EN: Get the current object instance size.
func (i *TIconOptions) InstanceSize() int32 {
return IconOptions_InstanceSize(i.instance)
}
// InheritsFrom
// CN: 判断当前类是否继承自指定类。
// EN: Determine whether the current class inherits from the specified class.
func (i *TIconOptions) InheritsFrom(AClass TClass) bool {
return IconOptions_InheritsFrom(i.instance, AClass)
}
// Equals
// CN: 与一个对象进行比较。
// EN: Compare with an object.
func (i *TIconOptions) Equals(Obj IObject) bool {
return IconOptions_Equals(i.instance, CheckPtr(Obj))
}
// GetHashCode
// CN: 获取类的哈希值。
// EN: Get the hash value of the class.
func (i *TIconOptions) GetHashCode() int32 {
return IconOptions_GetHashCode(i.instance)
}
// ToString
// CN: 文本类信息。
// EN: Text information.
func (i *TIconOptions) ToString() string {
return IconOptions_ToString(i.instance)
}
// Arrangement
func (i *TIconOptions) Arrangement() TIconArrangement {
return IconOptions_GetArrangement(i.instance)
}
// SetArrangement
func (i *TIconOptions) SetArrangement(value TIconArrangement) {
IconOptions_SetArrangement(i.instance, value)
}
// AutoArrange
func (i *TIconOptions) AutoArrange() bool {
return IconOptions_GetAutoArrange(i.instance)
}
// SetAutoArrange
func (i *TIconOptions) SetAutoArrange(value bool) {
IconOptions_SetAutoArrange(i.instance, value)
}