QGIS/python/core/auto_generated/layout/qgslayoutmeasurement.sip.in
Nyall Dawson 2ed144ac59 Apply clang-tidy readability-avoid-const-params-in-decls fixit
Checks whether a function declaration has parameters that are
top level const.

const values in declarations do not affect the signature of a
function, so they should not be put there.
2018-06-05 10:19:13 +10:00

108 lines
3.0 KiB
Plaintext

/************************************************************************
* This file has been generated automatically from *
* *
* src/core/layout/qgslayoutmeasurement.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/
class QgsLayoutMeasurement
{
%Docstring
This class provides a method of storing measurements for use in QGIS layouts
using a variety of different measurement units.
.. seealso:: :py:class:`QgsLayoutMeasurementConverter`
.. versionadded:: 3.0
%End
%TypeHeaderCode
#include "qgslayoutmeasurement.h"
%End
public:
explicit QgsLayoutMeasurement( double length, QgsUnitTypes::LayoutUnit units = QgsUnitTypes::LayoutMillimeters );
%Docstring
Constructor for QgsLayoutMeasurement.
:param length: measurement length
:param units: measurement units
%End
double length() const;
%Docstring
Returns the length of the measurement.
.. seealso:: :py:func:`setLength`
%End
void setLength( const double length );
%Docstring
Sets the ``length`` of the measurement.
.. seealso:: :py:func:`length`
%End
QgsUnitTypes::LayoutUnit units() const;
%Docstring
Returns the units for the measurement.
.. seealso:: :py:func:`setUnits`
%End
void setUnits( const QgsUnitTypes::LayoutUnit units );
%Docstring
Sets the ``units`` for the measurement. Does not alter the stored length,
ie. no length conversion is done.
.. seealso:: :py:func:`units`
%End
QString encodeMeasurement() const;
%Docstring
Encodes the layout measurement to a string
.. seealso:: :py:func:`decodeMeasurement`
%End
static QgsLayoutMeasurement decodeMeasurement( const QString &string );
%Docstring
Decodes a measurement from a ``string``.
.. seealso:: :py:func:`encodeMeasurement`
%End
bool operator==( const QgsLayoutMeasurement &other ) const;
bool operator!=( const QgsLayoutMeasurement &other ) const;
QgsLayoutMeasurement operator+( double v ) const;
QgsLayoutMeasurement operator+=( double v );
QgsLayoutMeasurement operator-( double v ) const;
QgsLayoutMeasurement operator-=( double v );
QgsLayoutMeasurement operator*( double v ) const;
QgsLayoutMeasurement operator*=( double v );
QgsLayoutMeasurement operator/( double v ) const;
QgsLayoutMeasurement operator/=( double v );
};
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/layout/qgslayoutmeasurement.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/