Skip to content
Permalink
Browse files

Add const version of QgsRenderContext::painter

  • Loading branch information
manisandro authored and nyalldawson committed Jan 15, 2020
1 parent 062600f commit 60b4cad0502d7f62c2ca0da78e10813b2595779d
Showing with 11 additions and 0 deletions.
  1. +1 −0 python/core/auto_generated/qgsrendercontext.sip.in
  2. +10 −0 src/core/qgsrendercontext.h
@@ -109,6 +109,7 @@ Returns the destination QPainter for the render operation.
.. seealso:: :py:func:`setPainter`
%End


QPainter *maskPainter( int id = 0 );
%Docstring
Returns a mask QPainter for the render operation.
@@ -170,6 +170,16 @@ class CORE_EXPORT QgsRenderContext
*/
QPainter *painter() {return mPainter;}

#ifndef SIP_RUN

/**
* Returns the const destination QPainter for the render operation.
* \see setPainter()
* \since QGIS 3.12
*/
const QPainter *painter() const { return mPainter; }
#endif

/**
* Returns a mask QPainter for the render operation.
* Multiple mask painters can be defined, each with a unique identifier.

0 comments on commit 60b4cad

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