2017-05-15 16:30:34 +02:00
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/core/qgsmargins.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
class QgsMargins
|
|
|
|
{
|
2017-05-14 09:48:41 +02:00
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
%TypeHeaderCode
|
2017-05-14 09:48:41 +02:00
|
|
|
#include "qgsmargins.h"
|
2017-01-30 10:50:48 +10:00
|
|
|
%End
|
|
|
|
public:
|
|
|
|
|
|
|
|
QgsMargins();
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Constructs a margins object with all margins set to 0.
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
QgsMargins( double left, double top, double right, double bottom );
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Constructs margins with the given ``left``, ``top``, ``right``, ``bottom``
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setLeft()`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRight()`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTop()`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setBottom()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
2017-01-30 10:50:48 +10:00
|
|
|
|
|
|
|
bool isNull() const;
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns \c true if all margins are is 0; otherwise returns false.
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
2017-01-30 10:50:48 +10:00
|
|
|
|
|
|
|
double left() const;
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the left margin.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setLeft()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
double top() const;
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the top margin.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setTop()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
double right() const;
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the right margin.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setRight()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
double bottom() const;
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the bottom margin.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`setBottom()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
2017-01-30 10:50:48 +10:00
|
|
|
|
|
|
|
void setLeft( double left );
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the left margin to ``left``.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`left()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
void setTop( double top );
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the top margin to ``top``.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`top()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
void setRight( double right );
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the right margin to ``right``.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`right()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
void setBottom( double bottom );
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the bottom margin to ``bottom``.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`bottom()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
2017-01-30 10:50:48 +10:00
|
|
|
|
|
|
|
QgsMargins &operator+=( const QgsMargins &margins );
|
2017-05-14 09:48:41 +02:00
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
QgsMargins &operator-=( const QgsMargins &margins );
|
2017-05-14 09:48:41 +02:00
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
QgsMargins &operator+=( double addend );
|
2017-05-14 09:48:41 +02:00
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
QgsMargins &operator-=( double subtrahend );
|
2017-05-14 09:48:41 +02:00
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
QgsMargins &operator*=( double factor );
|
2017-05-14 09:48:41 +02:00
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
QgsMargins &operator/=( double divisor );
|
|
|
|
|
|
|
|
QString toString() const;
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the margins encoded to a string.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`fromString()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
|
|
|
|
2017-05-01 16:42:33 +02:00
|
|
|
static QgsMargins fromString( const QString &string );
|
2017-05-14 09:48:41 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns a QgsMargins object decoded from a string, or a null QgsMargins
|
|
|
|
if the string could not be interpreted as margins.
|
|
|
|
|
2017-12-05 20:04:14 -04:00
|
|
|
.. seealso:: :py:func:`toString()`
|
2017-05-14 09:48:41 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-30 10:50:48 +10:00
|
|
|
};
|
|
|
|
|
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
bool operator==( const QgsMargins &lhs, const QgsMargins &rhs );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
bool operator!=( const QgsMargins &lhs, const QgsMargins &rhs );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
QgsMargins operator+( const QgsMargins &m1, const QgsMargins &m2 );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
QgsMargins operator-( const QgsMargins &m1, const QgsMargins &m2 );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
QgsMargins operator+( const QgsMargins &lhs, double rhs );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
QgsMargins operator+( double lhs, const QgsMargins &rhs );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
QgsMargins operator-( const QgsMargins &lhs, double rhs );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
QgsMargins operator*( const QgsMargins &margins, double factor );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
QgsMargins operator*( double factor, const QgsMargins &margins );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
QgsMargins operator/( const QgsMargins &margins, double divisor );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
QgsMargins operator+( const QgsMargins &margins );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
2017-05-14 19:51:16 +02:00
|
|
|
QgsMargins operator-( const QgsMargins &margins );
|
2017-05-15 16:30:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/core/qgsmargins.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|