Skip to content
Permalink
Browse files

Fixes in PyQGIS related to transfer of ownership in renderers.

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@7675 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
wonder
wonder committed Nov 27, 2007
1 parent 876b9e7 commit 08c26d8d24ce50c8d4f8c5993d1b60731e860848
@@ -17,9 +17,9 @@ class QgsContinuousColorRenderer : QgsRenderer
/**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);
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);
void setMaximumSymbol(QgsSymbol* sy /Transfer/);
/** Sets whether to draw the polygon outline*/
void setDrawPolygonOutline(bool draw);
/**Returns the symbol for the minimum value*/
@@ -43,6 +43,6 @@ class QgsContinuousColorRenderer : QgsRenderer
QString name() const;
/**Return symbology items*/
const QList<QgsSymbol*> symbols() const;
QgsRenderer* clone() const;
QgsRenderer* clone() const /Factory/;
};

@@ -11,7 +11,7 @@ class QgsGraduatedSymbolRenderer : QgsRenderer
virtual ~QgsGraduatedSymbolRenderer();
/**Adds a new item
\param sy a pointer to the QgsSymbol to be inserted. It has to be created using the new operator and is automatically destroyed when 'removeItems' is called or when this object is destroyed*/
void addSymbol(QgsSymbol* sy);
void addSymbol(QgsSymbol* sy /Transfer/);
/**Returns the number of the classification field*/
int classificationField() const;
/**Removes all symbols*/
@@ -43,6 +43,6 @@ class QgsGraduatedSymbolRenderer : QgsRenderer
/**Returns the symbols of the items*/
const QList<QgsSymbol*> symbols() const;
/**Returns a copy of the renderer (a deep copy on the heap)*/
QgsRenderer* clone() const;
QgsRenderer* clone() const /Factory/;
};

@@ -10,7 +10,7 @@ class QgsSingleSymbolRenderer : QgsRenderer
QgsSingleSymbolRenderer(const QgsSingleSymbolRenderer& other);
virtual ~QgsSingleSymbolRenderer();
/**Replaces the current mSymbol by sy*/
void addSymbol(QgsSymbol* sy);
void addSymbol(QgsSymbol* sy /Transfer/);
/*Returns a pointer to mSymbol*/
const QgsSymbol* symbol() const;
/**Renders an OGRFeature*/
@@ -33,6 +33,6 @@ class QgsSingleSymbolRenderer : QgsRenderer
/**Returns a list containing mSymbol*/
const QList<QgsSymbol*> symbols() const;
/**Returns a deep copy of this renderer*/
QgsRenderer* clone() const;
QgsRenderer* clone() const /Factory/;
};

@@ -26,7 +26,7 @@ class QgsUniqueValueRenderer : QgsRenderer
/**Returns the renderers name*/
QString name() const;
/**Inserts an entry into mEntries. The render items have to be created with the new operator and are automatically destroyed if not needed anymore*/
void insertValue(QString name, QgsSymbol* symbol);
void insertValue(QString name, QgsSymbol* symbol /Transfer/);
/**Removes all entries from mEntries*/
void clearValues();
/**Sets the Field index used for classification*/
@@ -35,6 +35,6 @@ class QgsUniqueValueRenderer : QgsRenderer
int classificationField();
/**Return symbology items*/
const QList<QgsSymbol*> symbols() const;
QgsRenderer* clone() const;
QgsRenderer* clone() const /Factory/;
};

0 comments on commit 08c26d8

Please sign in to comment.
You can’t perform that action at this time.