add_connector method

add_connector

Creates a new connector shape with default template styling and adds it to the end of the shape collection.

Returns

The newly created IConnector.

def add_connector(self, shape_type, x, y, width, height):
    ...
ParameterTypeDescription
shape_typeShapeTypeThe ShapeType of the connector shape to add.
xfloatThe x-coordinate of the connector’s frame, in points.
yfloatThe y-coordinate of the connector’s frame, in points.
widthfloatThe width of the connector’s frame, in points.
heightfloatThe height of the connector’s frame, in points.

Examples

The following example shows how to add a connector (a bent connector) between two shapes (an ellipse and rectangle) in PowerPoint Presentation.

add_connector

Creates a new connector shape and adds it to the end of the shape collection, optionally applying default template styling.

Returns

The newly created IConnector.

def add_connector(self, shape_type, x, y, width, height, create_from_template):
    ...
ParameterTypeDescription
shape_typeShapeTypeThe ShapeType of the connector shape to create.
xfloatThe x-coordinate of the connector’s frame, in points.
yfloatThe y-coordinate of the connector’s frame, in points.
widthfloatThe width of the connector’s frame, in points.
heightfloatThe height of the connector’s frame, in points.
create_from_templateboolTrue to apply default template styling (non-empty name, simple style);

false to create the connector with default property values.

See Also