QGIS API Documentation
4.3.0-Master (52aa6503bed)
Toggle main menu visibility
Loading...
Searching...
No Matches
src
gui
vectorfield
qgsvectorfieldsettingswidget.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsvectorfieldsettingswidget.h
3
-------------------------------------
4
begin : June 2018
5
copyright : (C) 2018 by Peter Petrik
6
email : zilolv 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 QGSVECTORFIELDSETTINGSWIDGET_H
17
#define QGSVECTORFIELDSETTINGSWIDGET_H
18
19
#include "ui_qgsvectorfieldsettingswidgetbase.h"
20
21
#include "
qgsvectorfieldsettings.h
"
22
23
#include <QWidget>
24
25
SIP_NO_FILE
26
27
class
QgsDoubleSpinBox
;
28
42
class
QgsVectorFieldSettingsWidget
:
public
QWidget,
private
Ui::QgsVectorFieldSettingsWidgetBase
43
{
44
Q_OBJECT
45
46
public
:
51
QgsVectorFieldSettingsWidget
( QWidget *parent =
nullptr
);
52
54
QgsVectorFieldSettings
settings
()
const
;
55
57
void
setSettings
(
const
QgsVectorFieldSettings
&
settings
);
58
63
void
setMagnitudeRange
(
double
minimum,
double
maximum );
64
73
void
setSupportsInterpolation
(
bool
supported );
74
84
void
setHasMagnitude
(
bool
hasMagnitude );
85
86
signals:
88
void
widgetChanged
();
89
90
private
slots:
91
void
onSymbologyChanged();
92
void
onStreamLineSeedingMethodChanged(
int
currentIndex );
93
void
onWindBarbUnitsChanged(
int
currentIndex );
94
void
onColoringMethodChanged();
95
void
onColorRampMinMaxChanged();
96
void
loadColorRampShader();
97
98
private
:
103
double
filterValue(
const
QgsDoubleSpinBox
*spinBox,
double
err_val )
const
;
104
106
void
applyMagnitudeSupport();
107
109
void
populateSymbologies();
110
112
Qgis::VectorFieldSymbology
currentSymbology()
const
;
113
114
bool
mSupportsInterpolation =
true
;
115
bool
mHasMagnitude =
true
;
116
bool
mHasMagnitudeRange =
false
;
117
double
mMagnitudeMinimum = 0;
118
double
mMagnitudeMaximum = 0;
119
};
120
121
#endif
// QGSVECTORFIELDSETTINGSWIDGET_H
Qgis::VectorFieldSymbology
VectorFieldSymbology
Defines the symbology of vector field rendering.
Definition
qgis.h:7234
QgsDoubleSpinBox
The QgsSpinBox is a spin box with a clear button that will set the value to the defined clear value.
Definition
qgsdoublespinbox.h:46
QgsVectorFieldSettingsWidget::settings
QgsVectorFieldSettings settings() const
Returns vector settings.
Definition
qgsvectorfieldsettingswidget.cpp:118
QgsVectorFieldSettingsWidget::QgsVectorFieldSettingsWidget
QgsVectorFieldSettingsWidget(QWidget *parent=nullptr)
A widget to hold the vector field symbology settings.
Definition
qgsvectorfieldsettingswidget.cpp:22
QgsVectorFieldSettingsWidget::setSupportsInterpolation
void setSupportsInterpolation(bool supported)
Sets whether the vector field behind the widget can be sampled between its data points.
Definition
qgsvectorfieldsettingswidget.cpp:196
QgsVectorFieldSettingsWidget::widgetChanged
void widgetChanged()
Vector field symbology settings changed.
QgsVectorFieldSettingsWidget::setSettings
void setSettings(const QgsVectorFieldSettings &settings)
Synchronizes the widgets state with settings.
Definition
qgsvectorfieldsettingswidget.cpp:214
QgsVectorFieldSettingsWidget::setHasMagnitude
void setHasMagnitude(bool hasMagnitude)
Sets whether the data behind the widget carries a magnitude.
Definition
qgsvectorfieldsettingswidget.cpp:202
QgsVectorFieldSettingsWidget::setMagnitudeRange
void setMagnitudeRange(double minimum, double maximum)
Sets the minimum and maximum magnitude of the data, which the color ramp shader is classified against...
Definition
qgsvectorfieldsettingswidget.cpp:207
QgsVectorFieldSettings
Represents a renderer settings for vector datasets.
Definition
qgsvectorfieldsettings.h:39
SIP_NO_FILE
#define SIP_NO_FILE
Definition
fromencodedcomponenthelper.h:23
qgsvectorfieldsettings.h
Generated on
for QGIS API Documentation by
1.17.0