---
name: "dtk_relrotate_shape"
section: "3"
platform: "linux"
package: "libdrawtk-dev"
version: "2.0-2.1"
release: "Debian 8 (Jessie)"
platforms: ["linux"]
url: "https://new.carta.tech/dtk_move_shape"
---

# dtk\_relrotate\_shape(3)

shape displacement

Part of [dtk\_move\_shape(3)](/dtk_move_shape/3.md).

## NAME

dtk\_move\_shape, dtk\_relmove\_shape, dtk\_rotate\_shape, dtk\_relrotate\_shape - shape displacement

## SYNOPSIS

**#include \<drawtk.h\>**

**void dtk\_move\_shape(dtk\_hshape** *shp***, float** *x***, float** *y***);**\
 **void dtk\_relmove\_shape(dtk\_hshape** *shp***, float** *dx***, float** *dy***);**\
 **void dtk\_rotate\_shape(dtk\_hshape** *shp***, float** *deg***);**\
 **void dtk\_relrotate\_shape(dtk\_hshape** *shp***, float** *ddeg***);**\

## DESCRIPTION

These functions control the position and the rotation with which the shape *shp* will be next drawn.

**dtk\_move\_shape**() set the translation the shape for the next draws. The position defined by *x* and *y* corresponds to the position of the origin of the shape (corresponding to the point (0,0) when the shape has been created).

**dtk\_rotate\_shape**() set the rotation (counter-clockwise) of the shape around its origin of the shape. This rotation is performed relatively to the initial posture of the shape (at creation time). The argument *deg* specify the angle of rotation expressed in degrees.

**dtk\_relmove\_shape**() and **dtk\_relrotate\_shape**() do the same excepting that their arguments *dx*, *dy* and *ddeg* updates the current parameters of the translation and rotation.

## RETURN VALUE

None of these functions returns value.

## SEE ALSO

[**dtk\_draw\_shape**(3)](/dtk_draw_shape/3.md)
