CODLabelComponent Class
class CODLabelComponent: public CODTextComponent
A label is a type of text component that is attached to a symbol. The symbol the label is attached to is referred to as the label owner. Labels can be positioned relative to a given point on the owner symbol or they can be free-floating. Orientation properties describe how the label is positioned with respect to the owner symbol. If the label is free- floating, then orientation is disabled.The following properties are added to the component by this class:
OD_PROP_ORIENTATION_ENABLED, OD_PROP_ORIENTATION, OD_PROP_LINEORIENTATION
Defined in: OdLabelComp.h
See Also
Component Property Identifiers
Class Members
Constructor.
CODLabelComponent(CODSymbolComponent* pOwner)
Constructor.
CODLabelComponent(const OD_CONTROL_POINT ctlPoint)
Constructor.
CODLabelComponent(const CODLabelComponent& src)
Copy constructor.
virtual ~CODLabelComponent()
Destructor.
BOOL Create(CDC* pDC=NULL)
Creates the label component.
CODLabelComponent& operator=(const CODLabelComponent& src)
Assignment operator.
virtual CODComponent* Dup() const
Create a duplicate copy of this object.
CODSymbolComponent* m_pOwner
A pointer to the symbol which owns this label.
CODSymbolComponent* GetOwner()
Get pointer to symbol that owns this port.
void SetOwner(CODSymbolComponent* pOwner)
Set pointer to symbol that owns this port.
CODOrientationProperties* GetOrientation()
Get orientation of the label with respect to its parent.
void SetOrientation(CODOrientationProperties& pProperty)
Set orientation of the label with respect to its parent.
void SetOrientation(const OD_CONTROL_POINT ctlPoint)
Set orientation of the label with respect to its parent.
void SetOrientationFlag(const BOOL bFlag)
Sets flag indicating if orientation is enabled.
BOOL GetOrientationFlag() const
Gets flag indicating if orientation is enabled.
virtual void UpdatePosition()
Updates the position of the label based on orientation.
virtual void OffsetLabel(const int nOffsetX, const int nOffsetY)
Moves label offsets relative to the control point.
virtual void SetProperty(CODProperty* pProperty)
Set the specified property.
virtual BOOL ChangeProperty(CODProperty* pProperty, DWORD dwChangeFlags = OD_CHANGE_ALL)
Change the specified property.
virtual void OnAdd(CODComponent* pParent)
Called by the framework when the component is added to a parent.
virtual void OnRemove(CODComponent* pParent)
Called by the framework when the component is removed from its parent.
virtual void OnMove()
Called by the framework when the component changes position.
virtual CODRgn UpdateRgn(const BOOL bNotifyParents = FALSE)
Update the region data and bounding rectangle based on current points, transforms, or any other criteria.
virtual const CODRgn& DoRgnUpdate()
Performs the work of updating the region of the component and its children.
virtual BOOL GroupCompatible(CODComponentSet* pCompSet) const
Test to determine if this component can be included in the given group.
virtual void Serialize(CArchive& ar)
Serializes the label component.