Skip to content
Permalink
Browse files

Improve API docs

  • Loading branch information
nyalldawson committed Jun 9, 2017
1 parent b0c35ab commit b2e102d2f5d6f831741f26963bfaaa9e0f94b3bf
Showing with 16 additions and 4 deletions.
  1. +6 −2 python/core/composer/qgscomposermap.sip
  2. +10 −2 src/core/composer/qgscomposermap.h
@@ -107,13 +107,17 @@ Sets new scene rectangle bounds and recalculates hight and extent

double scale() const;
%Docstring
Scale
Returns the map scale.
The scale value indicates the scale denominator, e.g. 1000.0 for a 1:1000 map.
.. seealso:: setNewScale()
:rtype: float
%End

void setNewScale( double scaleDenominator, bool forceUpdate = true );
%Docstring
Sets new scale and changes only mExtent
Sets new map ``scale`` and changes only the map extent.
The ``scale`` value indicates the scale denominator, e.g. 1000.0 for a 1:1000 map.
.. seealso:: scale()
%End

void setNewExtent( const QgsRectangle &extent );
@@ -126,10 +126,18 @@ class CORE_EXPORT QgsComposerMap : public QgsComposerItem
//! Sets new scene rectangle bounds and recalculates hight and extent
void setSceneRect( const QRectF &rectangle ) override;

//! \brief Scale
/**
* Returns the map scale.
* The scale value indicates the scale denominator, e.g. 1000.0 for a 1:1000 map.
* \see setNewScale()
*/
double scale() const;

//! Sets new scale and changes only mExtent
/**
* Sets new map \a scale and changes only the map extent.
* The \a scale value indicates the scale denominator, e.g. 1000.0 for a 1:1000 map.
* \see scale()
*/
void setNewScale( double scaleDenominator, bool forceUpdate = true );

/** Sets new extent for the map. This method may change the width or height of the map

0 comments on commit b2e102d

Please sign in to comment.
You can’t perform that action at this time.