Label
类:Label组件类
Constructor
new Glodon.Bimface.Tiles.UI.Label(option)
构造标签组件
Parameters:
| Name | Type | Description |
|---|---|---|
| option | Object | 构造标签的配置项 |
Methods
addClass(class)
对组件增加CSS样式
Parameters:
| Name | Type | Description |
|---|---|---|
| class | String | CSS类名 |
getDimensions()
获取组件的尺寸信息
Returns:
| Type | Description |
|---|---|
| Object | 组件的尺寸信息 |
getId()
获取ID
Returns:
| Type | Description |
|---|---|
| String | ID |
getPosition()
获取组件的位置信息
Returns:
| Type | Description |
|---|---|
| Object | 组件的位置信息 |
getText()
获取文字内容
Returns:
| Type | Description |
|---|---|
| String | 文字内容 |
hide()
隐藏
isVisible()
获取可见性状态
Returns:
| Type | Description |
|---|---|
| Boolean | 可见性状态 |
removeClass(class)
对组件移除CSS样式
Parameters:
| Name | Type | Description |
|---|---|---|
| class | String | CSS类名 |
setPosition(position)
设置组件的位置信息
Parameters:
| Name | Type | Description |
|---|---|---|
| position | Object | 组件的位置信息 |
setText(text)
设置文字内容
Parameters:
| Name | Type | Description |
|---|---|---|
| text | String | 文字内容 |
show()
显示