QGIS API Documentation 3.41.0-Master (cea29feecf2)
Loading...
Searching...
No Matches
qgsmeshrendererscalarsettingswidget.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsmeshrendererscalarsettingswidget.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 QGSMESHRENDERERSCALARSETTINGSWIDGET_H
17#define QGSMESHRENDERERSCALARSETTINGSWIDGET_H
18
19#include "ui_qgsmeshrendererscalarsettingswidgetbase.h"
20#include "qgis_gui.h"
22#include "qgsmeshdataprovider.h"
23
24#include <QWidget>
25
27
28class QgsMeshLayer;
29
38class GUI_EXPORT QgsMeshRendererScalarSettingsWidget : public QWidget, private Ui::QgsMeshRendererScalarSettingsWidgetBase
39{
40 Q_OBJECT
41
42 public:
47 QgsMeshRendererScalarSettingsWidget( QWidget *parent = nullptr );
48
50 void setLayer( QgsMeshLayer *layer );
51
53 void setActiveDatasetGroup( int groupIndex );
54
56 QgsMeshRendererScalarSettings settings() const;
57
59 void syncToLayer();
60
61 signals:
64
65 private slots:
66 void minMaxChanged();
67 void recalculateMinMaxButtonClicked();
68 void onEdgeStrokeWidthMethodChanged();
69
70 private:
71 double spinBoxValue( const QgsDoubleSpinBox *spinBox ) const;
72 QgsMeshRendererScalarSettings::DataResamplingMethod dataIntepolationMethod() const;
73
74 bool dataIsDefinedOnFaces() const;
75 bool dataIsDefinedOnEdges() const;
76
77 QgsMeshLayer *mMeshLayer = nullptr; // not owned
78 int mActiveDatasetGroup = -1;
79};
80
81#endif // QGSMESHRENDERERSCALARSETTINGSWIDGET_H
The QgsSpinBox is a spin box with a clear button that will set the value to the defined clear value.
Represents a mesh layer supporting display of data on structured or unstructured meshes.
A widget for setup of the scalar dataset renderer settings of a mesh layer.
void widgetChanged()
Mesh rendering settings changed.
Represents a mesh renderer settings for scalar datasets.
DataResamplingMethod
Resampling of value from dataset.
#define SIP_NO_FILE