-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added python bindings for vector field symbollayer
- Loading branch information
Showing
3 changed files
with
71 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
class QgsVectorFieldSymbolLayer: QgsMarkerSymbolLayerV2 | ||
{ | ||
%TypeHeaderCode | ||
#include <qgsvectorfieldsymbollayer.h> | ||
%End | ||
public: | ||
enum VectorFieldType | ||
{ | ||
Cartesian = 0, | ||
Polar, | ||
Height | ||
}; | ||
|
||
enum AngleOrientation | ||
{ | ||
ClockwiseFromNorth = 0, | ||
CounterclockwiseFromEast | ||
}; | ||
|
||
enum AngleUnits | ||
{ | ||
Degrees = 0, | ||
Radians | ||
}; | ||
|
||
QgsVectorFieldSymbolLayer(); | ||
~QgsVectorFieldSymbolLayer(); | ||
|
||
static QgsSymbolLayerV2* create( const QgsStringMap& properties ); | ||
|
||
QString layerType() const; | ||
|
||
bool setSubSymbol( QgsSymbolV2* symbol ); | ||
QgsSymbolV2* subSymbol(); | ||
|
||
void renderPoint( const QPointF& point, QgsSymbolV2RenderContext& context ); | ||
void startRender( QgsSymbolV2RenderContext& context ); | ||
void stopRender( QgsSymbolV2RenderContext& context ); | ||
|
||
QgsSymbolLayerV2* clone() const; | ||
QgsStringMap properties() const; | ||
|
||
void drawPreviewIcon( QgsSymbolV2RenderContext& context, QSize size ); | ||
|
||
QSet<QString> usedAttributes() const; | ||
|
||
//setters and getters | ||
void setXAttribute( const QString& attribute ); | ||
QString xAttribute() const; | ||
void setYAttribute( const QString& attribute ); | ||
QString yAttribute() const; | ||
void setScale( double s ); | ||
double scale() const; | ||
void setVectorFieldType( VectorFieldType type ); | ||
VectorFieldType vectorFieldType() const; | ||
void setAngleOrientation( AngleOrientation orientation ); | ||
AngleOrientation angleOrientation() const; | ||
void setAngleUnits( AngleUnits units ); | ||
AngleUnits angleUnits() const; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters