QGIS API Documentation 4.3.0-Master (2b7e6c9893e)
Loading...
Searching...
No Matches
qgsvectorfieldwindbarbsettings.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsvectorfieldwindbarbsettings.h
3 ---------------------
4 begin : September 2026
5 copyright : (C) 2026 by Stefanos Natsis
6 email : uclaros at gmail dot com
7 ***************************************************************************
8 * *
9 * This program is free software; you can redistribute it and/or modify *
10 * it under the terms of the GNU General Public License as published by *
11 * the Free Software Foundation; either version 2 of the License, or *
12 * (at your option) any later version. *
13 * *
14 ***************************************************************************/
15
16#ifndef QGSVECTORFIELDWINDBARBSETTINGS_H
17#define QGSVECTORFIELDWINDBARBSETTINGS_H
18
19#include "qgis.h"
20#include "qgis_core.h"
21
22#include <QDomElement>
23
32{
33 public:
38 double magnitudeMultiplier() const;
39
44
48 double shaftLength() const;
49
53 void setShaftLength( double shaftLength );
54
61
67 void setShaftLengthUnits( Qgis::RenderUnit shaftLengthUnit );
68
73
78
80 QDomElement writeXml( QDomDocument &doc ) const;
82 void readXml( const QDomElement &elem );
83
84 private:
85 double mShaftLength = 10;
88 double mMagnitudeMultiplier = 1;
89};
90
91#endif // QGSVECTORFIELDWINDBARBSETTINGS_H
WindSpeedUnit
Wind speed units.
Definition qgis.h:5662
@ MetersPerSecond
Meters per second.
Definition qgis.h:5663
RenderUnit
Rendering size units.
Definition qgis.h:5704
@ Millimeters
Millimeters.
Definition qgis.h:5705
Represents a mesh renderer settings for vector datasets displayed with wind barbs.
Qgis::WindSpeedUnit magnitudeUnits() const
Returns the units that the data are in.
double shaftLength() const
Returns the shaft length (in millimeters).
void readXml(const QDomElement &elem)
Reads configuration from the given DOM element.
QDomElement writeXml(QDomDocument &doc) const
Writes configuration to a new DOM element.
void setMagnitudeMultiplier(double magnitudeMultiplier)
Sets a multiplier for the magnitude to convert it to knots.
void setMagnitudeUnits(Qgis::WindSpeedUnit units)
Sets the units that the data are in.
double magnitudeMultiplier() const
Returns the multiplier for the magnitude to convert it to knots, according to the units set with setM...
void setShaftLength(double shaftLength)
Sets the shaft length (in millimeters).
Qgis::RenderUnit shaftLengthUnits() const
Returns the units for the shaft length.
void setShaftLengthUnits(Qgis::RenderUnit shaftLengthUnit)
Sets the units for the shaft length.