2008-05-15 08:13:05 +00:00
|
|
|
|
|
|
|
class QgsRenderContext
|
|
|
|
{
|
|
|
|
|
|
|
|
%TypeHeaderCode
|
|
|
|
#include <qgsrendercontext.h>
|
|
|
|
%End
|
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
public:
|
|
|
|
QgsRenderContext();
|
|
|
|
~QgsRenderContext();
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
//getters
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
QPainter* painter();
|
|
|
|
const QPainter* constPainter() const;
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
const QgsCoordinateTransform* coordinateTransform() const;
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
const QgsRectangle& extent() const;
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
const QgsMapToPixel& mapToPixel() const;
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
double scaleFactor() const;
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
double rasterScaleFactor() const;
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
bool renderingStopped() const;
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
bool forceVectorOutput() const;
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
bool drawEditingInformation() const;
|
2008-11-17 16:04:30 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
double rendererScale() const;
|
2009-11-18 18:46:12 +00:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
//! Added in QGIS v1.4
|
|
|
|
QgsLabelingEngineInterface* labelingEngine();
|
2008-05-15 08:13:05 +00:00
|
|
|
|
2013-04-12 00:35:21 +02:00
|
|
|
//! Added in QGIS v2.0
|
|
|
|
QColor selectionColor() const;
|
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
//setters
|
|
|
|
|
2012-12-17 08:55:31 +01:00
|
|
|
/**Sets coordinate transformation. QgsRenderContext does not take ownership*/
|
|
|
|
void setCoordinateTransform( const QgsCoordinateTransform* t );
|
2012-09-24 02:28:15 +02:00
|
|
|
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 );
|
|
|
|
//! Added in QGIS v1.5
|
|
|
|
void setForceVectorOutput( bool force );
|
|
|
|
//! Added in QGIS v1.4
|
|
|
|
void setLabelingEngine(QgsLabelingEngineInterface* iface);
|
2013-04-12 00:35:21 +02:00
|
|
|
//! Added in QGIS v2.0
|
|
|
|
void setSelectionColor( const QColor& color );
|
2008-05-15 08:13:05 +00:00
|
|
|
};
|