add_shape method

add_shape(new_shape, master_name, page_number)

Adds shape created by master to specific page.

Returns

The unique ID of the shape within shapes collection on the specified page.

def add_shape(self, new_shape, master_name, page_number):
    ...
Parameter Type Description
new_shape Shape New shape objectShape.
master_name str Master’s name.
page_number int Index of page.

add_shape(pin_x, pin_y, master_name, page_number)

Adds shape created by master on page with defined PinX and PinY.

Returns

The unique ID of the shape within shapes collection on the specified page.

def add_shape(self, pin_x, pin_y, master_name, page_number):
    ...
Parameter Type Description
pin_x float Specifies the x-coordinate of the shape’s pin (center of rotation) in relation to the page.
pin_y float Specifies the y-coordinate of the shape’s pin (center of rotation) in relation to the page.
master_name str Master’s name.
page_number int Index of page.

add_shape(pin_x, pin_y, width, height, master_name, page_number)

Adds shape created by master on page with defined PinX,PinY,Width and Height.

Returns

The unique ID of the shape within shapes collection on the specified page.

def add_shape(self, pin_x, pin_y, width, height, master_name, page_number):
    ...
Parameter Type Description
pin_x float Specifies the x-coordinate of the shape’s pin (center of rotation) in relation to the page.
pin_y float Specifies the y-coordinate of the shape’s pin (center of rotation) in relation to the page.
width float Specifies the width of the shape in inches.
height float Specifies the height of the shape in inches.
master_name str Master’s name.
page_number int Index of page.

See Also