AutoCAD.Entity

Inherits from AutoCAD.Object

Description

A class that encapsulates a drawable element of a DWG file.

This class is a FlexScript wrapper for the AcDbEntity class.

Properties

color Gets/sets the entity's color.
colorIndex Gets/sets the entity's color index.
entityType Returns the class name of the entity.
layer Gets/sets the entity's layer name.
linetype Gets/sets the entity's linetype.
linetypeScale Gets/sets the entity's linetype scale.
lineWeight Gets/sets the entity's line weight.
material Gets/sets the entity's material.
plotStyleName Gets/sets the entity's plot style name.
visibility Gets/sets the entity's visibility.

Methods

is True if the object is an instance of the defined FlexScript type.

Details

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.color

Color color

Description

Gets/sets the entity's color.

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.colorIndex

int colorIndex

Description

Gets/sets the entity's color index.

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.entityType

readonly string entityType

Description

Returns the class name of the entity.

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.layer

string layer

Description

Gets/sets the entity's layer name.

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.linetype

string linetype

Description

Gets/sets the entity's linetype.

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.linetypeScale

double linetypeScale

Description

Gets/sets the entity's linetype scale.

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.lineWeight

int lineWeight

Description

Gets/sets the entity's line weight.

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.material

string material

Description

Gets/sets the entity's material.

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.plotStyleName

string plotStyleName

Description

Gets/sets the entity's plot style name.

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.visibility

int visibility

Description

Gets/sets the entity's visibility.

Do no remove, this fixes the anchor on doc.flexsim.com

AutoCAD.Entity.is()

bool is( flexScriptType )

Parameters

flexScriptType The type.

Description

True if the object is an instance of the defined FlexScript type.

AutoCAD.Object obj = db.openObject(objId);
		if (obj.is(AutoCAD.BlockReference)) {
			AutoCAD.BlockReference ref = obj.as(AutoCAD.BlockReference);
			...
		}