-
-
Notifications
You must be signed in to change notification settings - Fork 3k
/
qgscontinuouscolorrenderer.sip
48 lines (45 loc) · 2.42 KB
/
qgscontinuouscolorrenderer.sip
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/**Renderer class which interpolates rgb values linear between the minimum and maximum value of the classification field*/
class QgsContinuousColorRenderer : QgsRenderer
{
%TypeHeaderCode
#include <qgscontinuouscolorrenderer.h>
%End
public:
QgsContinuousColorRenderer(QGis::VectorType type);
QgsContinuousColorRenderer(const QgsContinuousColorRenderer& other);
virtual ~QgsContinuousColorRenderer();
/**Renders the feature using the minimum and maximum value of the classification field*/
void renderFeature(QPainter* p, QgsFeature& f, QImage* img, bool selected, double widthScale = 1.0, double rasterScaleFactor = 1.0);
/**Returns the number of the classification field*/
int classificationField() const;
/**Sets the id of the classification field*/
void setClassificationField(int id);
/**Sets the symbol for the minimum value. The symbol has to be created using the new operator and is automatically deleted when inserting a new symbol or when the instance is destroyed*/
void setMinimumSymbol(QgsSymbol* sy /Transfer/);
/**Sets the symbol for the maximum value. The symbol has to be created using the new operator and is automatically deleted when inserting a new symbol or when the instance is destroyed*/
void setMaximumSymbol(QgsSymbol* sy /Transfer/);
/** Sets whether to draw the polygon outline*/
void setDrawPolygonOutline(bool draw);
/**Returns the symbol for the minimum value*/
const QgsSymbol* minimumSymbol() const;
/**Returns the symbol for the maximum value*/
const QgsSymbol* maximumSymbol() const;
/** whether to draw a polygon outline*/
bool drawPolygonOutline() const;
/**Reads the renderer configuration from an XML file
@param rnode the DOM node to read
@param vl the vector layer which will be associated with the renderer*/
virtual void readXML(const QDomNode& rnode, QgsVectorLayer& vl);
/**Writes the contents of the renderer to a configuration file
@ return true in case of success*/
virtual bool writeXML( QDomNode & layer_node, QDomDocument & document ) const;
/** Returns true*/
bool needsAttributes() const;
/**Returns a list with the index of the classification attribute*/
QList<int> classificationAttributes() const;
/**Returns the renderers name*/
QString name() const;
/**Return symbology items*/
const QList<QgsSymbol*> symbols() const;
QgsRenderer* clone() const /Factory/;
};