QgsRenderContext Class Reference
[QGIS core library]

Contains information about the context of a rendering operation. More...

#include <qgsrendercontext.h>

Collaboration diagram for QgsRenderContext:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 QgsRenderContext ()
 ~QgsRenderContext ()
QPainter * painter ()
const QgsCoordinateTransformcoordinateTransform () const
const QgsRectangleextent () const
const QgsMapToPixelmapToPixel () const
double scaleFactor () const
double rasterScaleFactor () const
bool renderingStopped () const
bool forceVectorOutput () const
bool drawEditingInformation () const
double rendererScale () const
QgsLabelingEngineInterfacelabelingEngine () const
 Added in QGIS v1.4.
void setCoordinateTransform (QgsCoordinateTransform *t)
 Sets coordinate transformation.
void setMapToPixel (const QgsMapToPixel &mtp)
void setExtent (const QgsRectangle &extent)
void setDrawEditingInformation (bool b)
void setRenderingStopped (bool stopped)
void setScaleFactor (double factor)
void setRasterScaleFactor (double factor)
void setRendererScale (double scale)
void setPainter (QPainter *p)
void setForceVectorOutput (bool force)
 Added in QGIS v1.5.
void setLabelingEngine (QgsLabelingEngineInterface *iface)
 Added in QGIS v1.4.

Private Attributes

QPainter * mPainter
 Painter for rendering operations.
QgsCoordinateTransformmCoordTransform
 For transformation between coordinate systems.
bool mDrawEditingInformation
 True if vertex markers for editing should be drawn.
QgsRectangle mExtent
bool mForceVectorOutput
 If true then no rendered vector elements should be cached as image.
QgsMapToPixel mMapToPixel
bool mRenderingStopped
 True if the rendering has been canceled.
double mScaleFactor
 Factor to scale line widths and point marker sizes.
double mRasterScaleFactor
 Factor to scale rasters.
double mRendererScale
 Map scale.
QgsLabelingEngineInterfacemLabelingEngine
 Labeling engine (can be NULL).


Detailed Description

Contains information about the context of a rendering operation.

The context of a rendering operation defines properties such as the conversion ratio between screen and map units, the extents / bounding box to be rendered etc.

Definition at line 35 of file qgsrendercontext.h.


Constructor & Destructor Documentation

QgsRenderContext::QgsRenderContext (  ) 

Definition at line 21 of file qgsrendercontext.cpp.

QgsRenderContext::~QgsRenderContext (  ) 

Definition at line 34 of file qgsrendercontext.cpp.

References mCoordTransform.


Member Function Documentation

QPainter* QgsRenderContext::painter (  )  [inline]

const QgsCoordinateTransform* QgsRenderContext::coordinateTransform (  )  const [inline]

const QgsRectangle& QgsRenderContext::extent (  )  const [inline]

const QgsMapToPixel& QgsRenderContext::mapToPixel (  )  const [inline]

double QgsRenderContext::scaleFactor (  )  const [inline]

double QgsRenderContext::rasterScaleFactor (  )  const [inline]

bool QgsRenderContext::renderingStopped (  )  const [inline]

bool QgsRenderContext::forceVectorOutput (  )  const [inline]

Definition at line 57 of file qgsrendercontext.h.

Referenced by QgsSimpleMarkerSymbolLayerV2::startRender().

bool QgsRenderContext::drawEditingInformation (  )  const [inline]

double QgsRenderContext::rendererScale (  )  const [inline]

QgsLabelingEngineInterface* QgsRenderContext::labelingEngine (  )  const [inline]

void QgsRenderContext::setCoordinateTransform ( QgsCoordinateTransform t  ) 

Sets coordinate transformation.

QgsRenderContext takes ownership and deletes if necessary

Definition at line 39 of file qgsrendercontext.cpp.

References mCoordTransform.

Referenced by QgsMapRenderer::render(), and QgsLabel::renderLabel().

void QgsRenderContext::setMapToPixel ( const QgsMapToPixel mtp  )  [inline]

void QgsRenderContext::setExtent ( const QgsRectangle extent  )  [inline]

void QgsRenderContext::setDrawEditingInformation ( bool  b  )  [inline]

Definition at line 72 of file qgsrendercontext.h.

Referenced by QgsComposerMap::draw(), and QgsMapRenderer::render().

void QgsRenderContext::setRenderingStopped ( bool  stopped  )  [inline]

void QgsRenderContext::setScaleFactor ( double  factor  )  [inline]

void QgsRenderContext::setRasterScaleFactor ( double  factor  )  [inline]

void QgsRenderContext::setRendererScale ( double  scale  )  [inline]

void QgsRenderContext::setPainter ( QPainter *  p  )  [inline]

void QgsRenderContext::setForceVectorOutput ( bool  force  )  [inline]

Added in QGIS v1.5.

Definition at line 79 of file qgsrendercontext.h.

Referenced by QgsComposerMap::draw().

void QgsRenderContext::setLabelingEngine ( QgsLabelingEngineInterface iface  )  [inline]

Added in QGIS v1.4.

Definition at line 81 of file qgsrendercontext.h.

Referenced by QgsMapRenderer::render().


Member Data Documentation

QPainter* QgsRenderContext::mPainter [private]

Painter for rendering operations.

Definition at line 86 of file qgsrendercontext.h.

For transformation between coordinate systems.

Can be 0 if on-the-fly reprojection is not used

Definition at line 89 of file qgsrendercontext.h.

Referenced by setCoordinateTransform(), and ~QgsRenderContext().

True if vertex markers for editing should be drawn.

Definition at line 92 of file qgsrendercontext.h.

Definition at line 94 of file qgsrendercontext.h.

If true then no rendered vector elements should be cached as image.

Definition at line 97 of file qgsrendercontext.h.

Definition at line 99 of file qgsrendercontext.h.

True if the rendering has been canceled.

Definition at line 102 of file qgsrendercontext.h.

Factor to scale line widths and point marker sizes.

Definition at line 105 of file qgsrendercontext.h.

Factor to scale rasters.

Definition at line 108 of file qgsrendercontext.h.

Map scale.

Definition at line 111 of file qgsrendercontext.h.

Labeling engine (can be NULL).

Definition at line 114 of file qgsrendercontext.h.


The documentation for this class was generated from the following files:

Generated on Sat Feb 4 19:17:48 2012 for Quantum GIS API Documentation by  doxygen 1.5.6