Skip to content

Commit d8a5dfe

Browse files
committedMay 21, 2019
Add missing dox to QgsRenderContext
1 parent e23ceaa commit d8a5dfe

File tree

2 files changed

+110
-0
lines changed

2 files changed

+110
-0
lines changed
 

‎python/core/auto_generated/qgsrendercontext.sip.in

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,11 @@ render and represents the exact bounds of the map being rendered.
203203
%End
204204

205205
const QgsMapToPixel &mapToPixel() const;
206+
%Docstring
207+
Returns the context's map to pixel transform, which transforms between map coordinates and device coordinates.
208+
209+
.. seealso:: :py:func:`setMapToPixel`
210+
%End
206211

207212
double scaleFactor() const;
208213
%Docstring
@@ -214,8 +219,20 @@ per millimeter.
214219
%End
215220

216221
bool renderingStopped() const;
222+
%Docstring
223+
Returns ``True`` if the rendering operation has been stopped and any ongoing
224+
rendering should be canceled immediately.
225+
226+
.. seealso:: :py:func:`setRenderingStopped`
227+
%End
217228

218229
bool forceVectorOutput() const;
230+
%Docstring
231+
Returns ``True`` if rendering operations should use vector operations instead
232+
of any faster raster shortcuts.
233+
234+
.. seealso:: :py:func:`setForceVectorOutput`
235+
%End
219236

220237
bool useAdvancedEffects() const;
221238
%Docstring
@@ -228,6 +245,11 @@ Used to enable or disable advanced effects such as blend modes
228245
%End
229246

230247
bool drawEditingInformation() const;
248+
%Docstring
249+
Returns ``True`` if edit markers should be drawn during the render operation.
250+
251+
.. seealso:: :py:func:`setDrawEditingInformation`
252+
%End
231253

232254
double rendererScale() const;
233255
%Docstring
@@ -239,6 +261,11 @@ for the rendered map, eg 1000.0 for a 1:1000 map render.
239261

240262

241263
QColor selectionColor() const;
264+
%Docstring
265+
Returns the color to use when rendering selected features.
266+
267+
.. seealso:: :py:func:`setSelectionColor`
268+
%End
242269

243270
bool showSelection() const;
244271
%Docstring
@@ -267,6 +294,11 @@ Set to an invalid QgsCoordinateTransform to indicate that no transformation is r
267294
%End
268295

269296
void setMapToPixel( const QgsMapToPixel &mtp );
297+
%Docstring
298+
Sets the context's map to pixel transform, which transforms between map coordinates and device coordinates.
299+
300+
.. seealso:: :py:func:`mapToPixel`
301+
%End
270302

271303
void setExtent( const QgsRectangle &extent );
272304
%Docstring
@@ -298,8 +330,19 @@ render and represents the exact bounds of the map being rendered.
298330
%End
299331

300332
void setDrawEditingInformation( bool b );
333+
%Docstring
334+
Sets whether edit markers should be drawn during the render operation.
335+
336+
.. seealso:: :py:func:`drawEditingInformation`
337+
%End
301338

302339
void setRenderingStopped( bool stopped );
340+
%Docstring
341+
Sets whether the rendering operation has been ``stopped`` and any ongoing
342+
rendering should be canceled immediately.
343+
344+
.. seealso:: :py:func:`renderingStopped`
345+
%End
303346

304347
void setDistanceArea( const QgsDistanceArea &distanceArea );
305348
%Docstring
@@ -336,8 +379,20 @@ of any rendering operations.
336379
%End
337380

338381
void setForceVectorOutput( bool force );
382+
%Docstring
383+
Sets whether rendering operations should use vector operations instead
384+
of any faster raster shortcuts.
385+
386+
.. seealso:: :py:func:`forceVectorOutput`
387+
%End
388+
339389

340390
void setSelectionColor( const QColor &color );
391+
%Docstring
392+
Sets the ``color`` to use when rendering selected features.
393+
394+
.. seealso:: :py:func:`selectionColor`
395+
%End
341396

342397
void setShowSelection( bool showSelection );
343398
%Docstring

‎src/core/qgsrendercontext.h

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -249,6 +249,11 @@ class CORE_EXPORT QgsRenderContext
249249
*/
250250
QgsRectangle mapExtent() const { return mOriginalMapExtent; }
251251

252+
/**
253+
* Returns the context's map to pixel transform, which transforms between map coordinates and device coordinates.
254+
*
255+
* \see setMapToPixel()
256+
*/
252257
const QgsMapToPixel &mapToPixel() const {return mMapToPixel;}
253258

254259
/**
@@ -259,8 +264,20 @@ class CORE_EXPORT QgsRenderContext
259264
*/
260265
double scaleFactor() const {return mScaleFactor;}
261266

267+
/**
268+
* Returns TRUE if the rendering operation has been stopped and any ongoing
269+
* rendering should be canceled immediately.
270+
*
271+
* \see setRenderingStopped()
272+
*/
262273
bool renderingStopped() const {return mRenderingStopped;}
263274

275+
/**
276+
* Returns TRUE if rendering operations should use vector operations instead
277+
* of any faster raster shortcuts.
278+
*
279+
* \see setForceVectorOutput()
280+
*/
264281
bool forceVectorOutput() const;
265282

266283
/**
@@ -273,6 +290,11 @@ class CORE_EXPORT QgsRenderContext
273290
*/
274291
void setUseAdvancedEffects( bool enabled );
275292

293+
/**
294+
* Returns TRUE if edit markers should be drawn during the render operation.
295+
*
296+
* \see setDrawEditingInformation()
297+
*/
276298
bool drawEditingInformation() const;
277299

278300
/**
@@ -288,6 +310,11 @@ class CORE_EXPORT QgsRenderContext
288310
*/
289311
QgsLabelingEngine *labelingEngine() const { return mLabelingEngine; } SIP_SKIP
290312

313+
/**
314+
* Returns the color to use when rendering selected features.
315+
*
316+
* \see setSelectionColor()
317+
*/
291318
QColor selectionColor() const { return mSelectionColor; }
292319

293320
/**
@@ -313,6 +340,11 @@ class CORE_EXPORT QgsRenderContext
313340
*/
314341
void setCoordinateTransform( const QgsCoordinateTransform &t );
315342

343+
/**
344+
* Sets the context's map to pixel transform, which transforms between map coordinates and device coordinates.
345+
*
346+
* \see mapToPixel()
347+
*/
316348
void setMapToPixel( const QgsMapToPixel &mtp ) {mMapToPixel = mtp;}
317349

318350
/**
@@ -341,8 +373,19 @@ class CORE_EXPORT QgsRenderContext
341373
*/
342374
void setMapExtent( const QgsRectangle &extent ) { mOriginalMapExtent = extent; }
343375

376+
/**
377+
* Sets whether edit markers should be drawn during the render operation.
378+
*
379+
* \see drawEditingInformation()
380+
*/
344381
void setDrawEditingInformation( bool b );
345382

383+
/**
384+
* Sets whether the rendering operation has been \a stopped and any ongoing
385+
* rendering should be canceled immediately.
386+
*
387+
* \see renderingStopped()
388+
*/
346389
void setRenderingStopped( bool stopped ) {mRenderingStopped = stopped;}
347390

348391
/**
@@ -375,13 +418,25 @@ class CORE_EXPORT QgsRenderContext
375418
*/
376419
void setPainter( QPainter *p ) {mPainter = p;}
377420

421+
/**
422+
* Sets whether rendering operations should use vector operations instead
423+
* of any faster raster shortcuts.
424+
*
425+
* \see forceVectorOutput()
426+
*/
378427
void setForceVectorOutput( bool force );
379428

380429
/**
381430
* Assign new labeling engine
382431
* \note not available in Python bindings
383432
*/
384433
void setLabelingEngine( QgsLabelingEngine *engine2 ) { mLabelingEngine = engine2; } SIP_SKIP
434+
435+
/**
436+
* Sets the \a color to use when rendering selected features.
437+
*
438+
* \see selectionColor()
439+
*/
385440
void setSelectionColor( const QColor &color ) { mSelectionColor = color; }
386441

387442
/**

0 commit comments

Comments
 (0)