---
title: Class: DbAttributeDefinition
source: https://vjmap.com/doc/Class_DbAttributeDefinition.html
---

# Class: DbAttributeDefinition

[default](#modulesdefaultmd).DbAttributeDefinition

`DbText` 属性定义实体.

### Hierarchy

- [*DbText*](#classesdefaultdbtextmd)

  ↳ **DbAttributeDefinition**

### Table of contents

#### Constructors

- [constructor](#constructor)

#### Properties

- [alpha](#alpha)
- [cloneFromDb](#clonefromdb)
- [cloneObjectId](#cloneobjectid)
- [color](#color)
- [colorIndex](#colorindex)
- [contents](#contents)
- [height](#height)
- [horizontalMode](#horizontalmode)
- [layer](#layer)
- [lineWidth](#linewidth)
- [linetype](#linetype)
- [linetypeScale](#linetypescale)
- [matrix](#matrix)
- [position](#position)
- [prompt](#prompt)
- [rotation](#rotation)
- [tag](#tag)
- [text](#text)
- [textStyle](#textstyle)
- [typename](#typename)
- [verticalMode](#verticalmode)
- [visibility](#visibility)
- [xdata](#xdata)

### Constructors

#### constructor

\+ **new DbAttributeDefinition**(`prop?`: [*IDbText*](#interfacesdefaultidbtextmd)): [*DbAttributeDefinition*](#classesdefaultdbattributedefinitionmd)

构造函数

##### Parameters

| Name | Type | Default value |
| :------ | :------ | :------ |
| `prop` | [*IDbText*](#interfacesdefaultidbtextmd) | {} |

**Returns:** [*DbAttributeDefinition*](#classesdefaultdbattributedefinitionmd)

Overrides: [DbText](#classesdefaultdbtextmd)

### Properties

#### alpha

• `Optional` **alpha**: *number*

透明度. [0-255][0完全透明,255完全不透明]

Inherited from: [DbText](#classesdefaultdbtextmd).[alpha](#alpha)

___

#### cloneFromDb

• `Optional` **cloneFromDb**: *string*

克隆的实体ID来源的图形，如为空，则取DbDocument中from的图形。也可以指定另外的图形

Inherited from: [DbText](#classesdefaultdbtextmd).[cloneFromDb](#clonefromdb)

___

#### cloneObjectId

• `Optional` **cloneObjectId**: *string*

克隆的实体ID，DbDocument有from图形来源字段时有效.

Inherited from: [DbText](#classesdefaultdbtextmd).[cloneObjectId](#cloneobjectid)

___

#### color

• `Optional` **color**: *number*

颜色.

Inherited from: [DbText](#classesdefaultdbtextmd).[color](#color)

___

#### colorIndex

• `Optional` **colorIndex**: *number*

颜色索引. 0 随块. 1 Red.  2 Yellow. 3   Green.  4 Cyan.  5  Blue. 6   Magenta. 256 表示随层

Inherited from: [DbText](#classesdefaultdbtextmd).[colorIndex](#colorindex)

___

#### contents

• `Optional` **contents**: *string*

文本内容， 同text.

Inherited from: [DbText](#classesdefaultdbtextmd).[contents](#contents)

___

#### height

• `Optional` **height**: *number*

高.

Inherited from: [DbText](#classesdefaultdbtextmd).[height](#height)

___

#### horizontalMode

• `Optional` **horizontalMode**: [*kTextLeft*](#ktextleft) \| [*kTextCenter*](#ktextcenter) \| [*kTextRight*](#ktextright) \| [*kTextAlign*](#ktextalign) \| [*kTextMid*](#ktextmid) \| [*kTextFit*](#ktextfit)

水平模式.

Inherited from: [DbText](#classesdefaultdbtextmd).[horizontalMode](#horizontalmode)

___

#### layer

• `Optional` **layer**: *string*

图层.

Inherited from: [DbText](#classesdefaultdbtextmd).[layer](#layer)

___

#### lineWidth

• `Optional` **lineWidth**: *number*

线宽.

Inherited from: [DbText](#classesdefaultdbtextmd).[lineWidth](#linewidth)

___

#### linetype

• `Optional` **linetype**: *string*

线型.

Inherited from: [DbText](#classesdefaultdbtextmd).[linetype](#linetype)

___

#### linetypeScale

• `Optional` **linetypeScale**: *number*

线型比例.

Inherited from: [DbText](#classesdefaultdbtextmd).[linetypeScale](#linetypescale)

___

#### matrix

• `Optional` **matrix**: [*IDbMatrixOp*](#interfacesdefaultidbmatrixopmd)[]

矩阵.

Inherited from: [DbText](#classesdefaultdbtextmd).[matrix](#matrix)

___

#### position

• `Optional` **position**: [*number*, *number*, *undefined* \| *number*]

位置.

Inherited from: [DbText](#classesdefaultdbtextmd).[position](#position)

___

#### prompt

• `Optional` **prompt**: *string*

属性提示.

___

#### rotation

• `Optional` **rotation**: *number*

旋转角度.

Inherited from: [DbText](#classesdefaultdbtextmd).[rotation](#rotation)

___

#### tag

• `Optional` **tag**: *string*

属性名.

___

#### text

• `Optional` **text**: *string*

文本内容， 同contents.

Inherited from: [DbText](#classesdefaultdbtextmd).[text](#text)

___

#### textStyle

• `Optional` **textStyle**: *string*

文本样式.

Inherited from: [DbText](#classesdefaultdbtextmd).[textStyle](#textstyle)

___

#### typename

• `Optional` **typename**: *string*

类型.

Inherited from: [DbText](#classesdefaultdbtextmd).[typename](#typename)

___

#### verticalMode

• `Optional` **verticalMode**: [*kTextBase*](#ktextbase) \| [*kTextBottom*](#ktextbottom) \| [*kTextVertMid*](#ktextvertmid) \| [*kTextTop*](#ktexttop)

垂直模式.

Inherited from: [DbText](#classesdefaultdbtextmd).[verticalMode](#verticalmode)

___

#### visibility

• `Optional` **visibility**: *boolean*

可见.

Inherited from: [DbText](#classesdefaultdbtextmd).[visibility](#visibility)

___

#### xdata

• `Optional` **xdata**: *string*

扩展数据.

Inherited from: [DbText](#classesdefaultdbtextmd).[xdata](#xdata)


<a name="classesdefaultdbblockmd"></a>

[vjmap](#readmemd) / [Exports](#modulesmd) / [default](#modulesdefaultmd) / DbBlock
