C++
virtual ACDBCORE2D_PORT Acad::ErrorStatus setVisibility( AcDb::Visibility newVal, bool doSubents = true );
Description
This method sets the visibility of an entity to the value specified by newVal. If the entity owns subentities and doSubents == Adesk::kTrue, then the visibility change will be applied to the subentities as well.
The only built-in entities for which kTrue has an effect are: AcDb2dPolyline, AcDb3dPolyline, AcDbPolyFaceMesh, and AcDbPolygonMesh.
Returns Acad::eOk if successful.
Function implementation in derived classes
If this function is overridden and wishes to set the visibility of the entity, then it must call AcDbEntity::setVisibility() passing on the newVal and doSubents arguments.
It is also possible for this function's implementation to deal directly with any subentities and pass a doSubents value of Adesk::kFalse to AcDbEntity::setVisibility().
If the color setting operation is successful, then this function should return Acad::eOk. If color is not an acceptable value, then this function should return Acad::eInvalidIndex. Any other error return values are up to the implementer.
Parameters
Parameters | Description |
---|---|
newVal | Input visibility value to which the entity will be set; possible AcDb::Visibility values are:AcDb::kInvisibleAcDb::kVisible |
doSubents | Input Boolean indicating whether to propagate the change to any subentities the entity may own |
Links
Previous Declaration
ACDBCORE2D_PORT ADESK_SEALED_VIRTUAL Acad::ErrorStatus setVisibility(AcDb::Visibility newVal, Adesk::Boolean doSubents = true) ADESK_SEALED;