2017-05-23 14:33:31 +02:00
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/core/effects/qgstransformeffect.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
class QgsTransformEffect : QgsPaintEffect
|
|
|
|
{
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
|
|
|
A paint effect which applies transformations (such as move,
|
2017-12-15 10:36:55 -04:00
|
|
|
scale and rotate) to a picture.
|
2017-05-23 14:33:31 +02:00
|
|
|
|
|
|
|
.. versionadded:: 2.9
|
2015-03-28 20:03:37 +11:00
|
|
|
%End
|
2015-04-07 14:27:39 +02:00
|
|
|
|
2017-05-23 14:33:31 +02:00
|
|
|
%TypeHeaderCode
|
|
|
|
#include "qgstransformeffect.h"
|
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
public:
|
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
static QgsPaintEffect *create( const QgsStringMap &map ) /Factory/;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Creates a new QgsTransformEffect effect from a properties string map.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param map: encoded properties string map
|
|
|
|
|
|
|
|
:return: new QgsTransformEffect
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
QgsTransformEffect();
|
2017-09-28 08:17:06 +10:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Constructor for QgsTransformEffect.
|
2017-09-28 08:17:06 +10:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
virtual QString type() const;
|
|
|
|
virtual QgsStringMap properties() const;
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
virtual void readProperties( const QgsStringMap &props );
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
virtual QgsTransformEffect *clone() const /Factory/;
|
2015-03-28 20:03:37 +11:00
|
|
|
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2015-03-28 20:03:37 +11:00
|
|
|
void setTranslateX( const double translateX );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the transform x translation.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param translateX: distance to translate along the x axis
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateMapUnitScale`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
double translateX() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the transform x translation.
|
|
|
|
|
|
|
|
:return: X distance translated along the x axis
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateMapUnitScale`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
void setTranslateY( const double translateY );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the transform y translation.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param translateY: distance to translate along the y axis
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateMapUnitScale`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
double translateY() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the transform y translation.
|
|
|
|
|
|
|
|
:return: Y distance translated along the y axis
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateMapUnitScale`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
2016-07-17 22:11:17 +10:00
|
|
|
void setTranslateUnit( const QgsUnitTypes::RenderUnit unit );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the units used for the transform translation.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param unit: units for translation
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateMapUnitScale`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
2016-07-17 22:11:17 +10:00
|
|
|
QgsUnitTypes::RenderUnit translateUnit() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the units used for the transform translation.
|
|
|
|
|
|
|
|
:return: units for translation
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateUnit`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateMapUnitScale`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
void setTranslateMapUnitScale( const QgsMapUnitScale &scale );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the map unit scale used for the transform translation.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param scale: map unit scale for translation
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateMapUnitScale`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateUnit`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
const QgsMapUnitScale &translateMapUnitScale() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the map unit scale used for the transform translation.
|
|
|
|
|
|
|
|
:return: map unit scale for translation
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTranslateMapUnitScale`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`translateUnit`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
void setScaleX( const double scaleX );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the x axis scaling factor.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param scaleX: factor to scale x axis by, where 1.0 = no scaling
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`scaleX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setScaleY`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
double scaleX() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the x axis scaling factor.
|
|
|
|
|
|
|
|
:return: x axis scaling factor, where 1.0 = no scaling
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setScaleX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`scaleY`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
void setScaleY( const double scaleY );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the y axis scaling factor.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param scaleY: factor to scale y axis by, where 1.0 = no scaling
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`scaleX`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
double scaleY() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the y axis scaling factor.
|
|
|
|
|
|
|
|
:return: y axis scaling factor, where 1.0 = no scaling
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setScaleY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`scaleX`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
void setRotation( const double rotation );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the transform ``rotation``, in degrees clockwise.
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`rotation`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
double rotation() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the transform rotation, in degrees clockwise.
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setRotation`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
void setShearX( const double shearX );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the x axis shearing factor.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param shearX: x axis shearing
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`shearX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setShearY`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
double shearX() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the x axis shearing factor.
|
|
|
|
|
|
|
|
:return: x axis shearing
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setShearX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`shearY`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
void setShearY( const double shearY );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the y axis shearing factor.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param shearY: y axis shearing
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`shearY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setShearX`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
double shearY() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the y axis shearing factor.
|
|
|
|
|
|
|
|
:return: y axis shearing
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setShearY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`shearX`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
void setReflectX( const bool reflectX );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets whether to reflect along the x-axis
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param reflectX: true to reflect horizontally
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`reflectX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setReflectY`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
bool reflectX() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns whether transform will be reflected along the x-axis
|
|
|
|
|
|
|
|
:return: true if transform will reflect horizontally
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setReflectX`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`reflectY`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
void setReflectY( const bool reflectY );
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets whether to reflect along the y-axis
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param reflectY: true to reflect horizontally
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`reflectY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setReflectX`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
bool reflectY() const;
|
2017-05-23 14:33:31 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns whether transform will be reflected along the y-axis
|
|
|
|
|
|
|
|
:return: true if transform will reflect horizontally
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setReflectY`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`reflectX`
|
2017-05-23 14:33:31 +02:00
|
|
|
%End
|
2015-03-28 20:03:37 +11:00
|
|
|
|
|
|
|
protected:
|
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
virtual void draw( QgsRenderContext &context );
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-05-01 18:13:15 +02:00
|
|
|
virtual QRectF boundingRect( const QRectF &rect, const QgsRenderContext &context ) const;
|
2015-03-28 20:03:37 +11:00
|
|
|
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2015-03-28 20:03:37 +11:00
|
|
|
};
|
2017-05-23 14:33:31 +02:00
|
|
|
|
|
|
|
|
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/core/effects/qgstransformeffect.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|