CODOrthogonalLinkShape::Dock

BOOLCODOrthogonalLinkShape::Dock(CODPortComponent*pSourcePort, CODPortComponent*pTargetPort)

Adjusts the shape so that the head and tail dock with the given ports.

Defined in: OdLinkShape.cpp

Return Value

TRUE if shape changed; otherwise FALSE.

Parameters

pSourcePort

Pointer to port connected to the tail of the link.

pTargetPort

Pointer to port connected to the head of the link.

Comments

This function reconfigures the line so that the tail and head of the line are positioned to the location of the source port and target port. If a port returns TRUE from  CODPortComponent::MustAttachAtPerimeter, the corresponding line endpoint is adjusted to the perimeter of the symbol that owns the port. This function also calls  CODLineComponent::MakeOrthogonal if necessary, to keep the line orthogonal.