2012-09-24 02:28:15 +02:00
|
|
|
class QgsVectorFieldSymbolLayer : QgsMarkerSymbolLayerV2
|
2011-11-15 16:22:46 +01:00
|
|
|
{
|
2011-11-16 17:52:20 +02:00
|
|
|
%TypeHeaderCode
|
|
|
|
#include <qgsvectorfieldsymbollayer.h>
|
|
|
|
%End
|
2011-11-15 16:22:46 +01:00
|
|
|
public:
|
|
|
|
enum VectorFieldType
|
|
|
|
{
|
|
|
|
Cartesian = 0,
|
|
|
|
Polar,
|
|
|
|
Height
|
|
|
|
};
|
|
|
|
|
|
|
|
enum AngleOrientation
|
|
|
|
{
|
|
|
|
ClockwiseFromNorth = 0,
|
|
|
|
CounterclockwiseFromEast
|
|
|
|
};
|
|
|
|
|
|
|
|
enum AngleUnits
|
|
|
|
{
|
|
|
|
Degrees = 0,
|
|
|
|
Radians
|
|
|
|
};
|
|
|
|
|
|
|
|
QgsVectorFieldSymbolLayer();
|
|
|
|
~QgsVectorFieldSymbolLayer();
|
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
static QgsSymbolLayerV2* create( const QgsStringMap& properties = QgsStringMap() );
|
|
|
|
static QgsSymbolLayerV2* createFromSld( QDomElement &element );
|
2011-11-15 16:22:46 +01:00
|
|
|
|
|
|
|
QString layerType() const;
|
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
bool setSubSymbol( QgsSymbolV2* symbol /Transfer/ );
|
2011-11-15 16:22:46 +01:00
|
|
|
QgsSymbolV2* subSymbol();
|
|
|
|
|
|
|
|
void renderPoint( const QPointF& point, QgsSymbolV2RenderContext& context );
|
|
|
|
void startRender( QgsSymbolV2RenderContext& context );
|
|
|
|
void stopRender( QgsSymbolV2RenderContext& context );
|
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
QgsSymbolLayerV2* clone() const /Factory/;
|
2011-11-15 16:22:46 +01:00
|
|
|
QgsStringMap properties() const;
|
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
void toSld( QDomDocument& doc, QDomElement &element, QgsStringMap props ) const;
|
|
|
|
|
2011-11-15 16:22:46 +01:00
|
|
|
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;
|
2011-11-16 17:52:20 +02:00
|
|
|
};
|