Quantum GIS API Documentation
1.7.5-Wroclaw
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
src
core
qgsrendercontext.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsrendercontext.h
3
------------------
4
begin : March 16, 2008
5
copyright : (C) 2008 by Marco Hugentobler
6
email : marco dot hugentobler at karto dot baug dot ethz dot ch
7
***************************************************************************/
8
9
/***************************************************************************
10
* *
11
* This program is free software; you can redistribute it and/or modify *
12
* it under the terms of the GNU General Public License as published by *
13
* the Free Software Foundation; either version 2 of the License, or *
14
* (at your option) any later version. *
15
* *
16
***************************************************************************/
17
18
#ifndef QGSRENDERCONTEXT_H
19
#define QGSRENDERCONTEXT_H
20
21
#include "
qgscoordinatetransform.h
"
22
#include "
qgsmaptopixel.h
"
23
#include "
qgsrectangle.h
"
24
25
class
QPainter;
26
27
class
QgsLabelingEngineInterface
;
28
35
class
CORE_EXPORT
QgsRenderContext
36
{
37
public
:
38
QgsRenderContext
();
39
~
QgsRenderContext
();
40
41
//getters
42
43
QPainter*
painter
() {
return
mPainter;}
44
const
QPainter*
constPainter
()
const
{
return
mPainter; }
45
46
const
QgsCoordinateTransform
*
coordinateTransform
()
const
{
return
mCoordTransform;}
47
48
const
QgsRectangle
&
extent
()
const
{
return
mExtent;}
49
50
const
QgsMapToPixel
&
mapToPixel
()
const
{
return
mMapToPixel;}
51
52
double
scaleFactor
()
const
{
return
mScaleFactor;}
53
54
double
rasterScaleFactor
()
const
{
return
mRasterScaleFactor;}
55
56
bool
renderingStopped
()
const
{
return
mRenderingStopped;}
57
58
bool
forceVectorOutput
()
const
{
return
mForceVectorOutput;}
59
60
bool
drawEditingInformation
()
const
{
return
mDrawEditingInformation;}
61
62
double
rendererScale
()
const
{
return
mRendererScale;}
63
65
QgsLabelingEngineInterface
*
labelingEngine
()
const
{
return
mLabelingEngine; }
66
67
//setters
68
70
void
setCoordinateTransform(
QgsCoordinateTransform
* t );
71
void
setMapToPixel
(
const
QgsMapToPixel
& mtp ) {mMapToPixel = mtp;}
72
void
setExtent
(
const
QgsRectangle
& extent ) {mExtent = extent;}
73
void
setDrawEditingInformation
(
bool
b ) {mDrawEditingInformation = b;}
74
void
setRenderingStopped
(
bool
stopped ) {mRenderingStopped = stopped;}
75
void
setScaleFactor
(
double
factor ) {mScaleFactor = factor;}
76
void
setRasterScaleFactor
(
double
factor ) {mRasterScaleFactor = factor;}
77
void
setRendererScale
(
double
scale ) {mRendererScale = scale;}
78
void
setPainter
( QPainter* p ) {mPainter = p;}
80
void
setForceVectorOutput
(
bool
force ) {mForceVectorOutput = force;}
82
void
setLabelingEngine
(
QgsLabelingEngineInterface
* iface ) { mLabelingEngine = iface; }
83
84
private
:
85
87
QPainter*
mPainter
;
88
90
QgsCoordinateTransform
*
mCoordTransform
;
91
93
bool
mDrawEditingInformation
;
94
95
QgsRectangle
mExtent
;
96
98
bool
mForceVectorOutput
;
99
100
QgsMapToPixel
mMapToPixel
;
101
103
bool
mRenderingStopped
;
104
106
double
mScaleFactor
;
107
109
double
mRasterScaleFactor
;
110
112
double
mRendererScale
;
113
115
QgsLabelingEngineInterface
*
mLabelingEngine
;
116
};
117
118
#endif
Generated on Thu Sep 19 2013 17:30:54 for Quantum GIS API Documentation by
1.8.4