QGIS API Documentation  2.99.0-Master (e077efd)
qgspointdisplacementrendererwidget.h
Go to the documentation of this file.
1 /***************************************************************************
2  qgspointdisplacementrendererwidget.h
3  ------------------------------------
4  begin : January 26, 2010
5  copyright : (C) 2010 by Marco Hugentobler
6  email : marco at hugis dot net
7  ***************************************************************************/
8 
9 /***************************************************************************
10  * *
11  * This program is free software; you can redistribute it and/or modify *
12  * it under the terms of the GNU General Public License as published by *
13  * the Free Software Foundation; either version 2 of the License, or *
14  * (at your option) any later version. *
15  * *
16  ***************************************************************************/
17 
18 #ifndef QGSPOINTDISPLACEMENTRENDERERWIDGET_H
19 #define QGSPOINTDISPLACEMENTRENDERERWIDGET_H
20 
21 #include "ui_qgspointdisplacementrendererwidgetbase.h"
22 #include "qgsrendererwidget.h"
23 
25 
29 class GUI_EXPORT QgsPointDisplacementRendererWidget: public QgsRendererWidget, private Ui::QgsPointDisplacementRendererWidgetBase
30 {
31  Q_OBJECT
32  public:
33  static QgsRendererWidget* create( QgsVectorLayer* layer, QgsStyle* style, QgsFeatureRenderer* renderer );
36 
37  QgsFeatureRenderer* renderer() override;
38  void setContext( const QgsSymbolWidgetContext& context ) override;
39 
40  private:
42 
43  void blockAllSignals( bool block );
44  void updateCenterIcon();
45  void setupBlankUi( const QString& layerName );
46 
47  private slots:
48  void on_mLabelFieldComboBox_currentIndexChanged( const QString& text );
49  void on_mRendererComboBox_currentIndexChanged( int index );
50  void on_mPlacementComboBox_currentIndexChanged( int index );
51  void on_mLabelFontButton_clicked();
52  void on_mCircleWidthSpinBox_valueChanged( double d );
53  void on_mCircleColorButton_colorChanged( const QColor& newColor );
54  void on_mDistanceSpinBox_valueChanged( double d );
55  void on_mDistanceUnitWidget_changed();
56  void on_mLabelColorButton_colorChanged( const QColor& newColor );
57  void on_mCircleModificationSpinBox_valueChanged( double d );
58  void on_mScaleDependentLabelsCheckBox_stateChanged( int state );
59  void on_mMaxScaleDenominatorEdit_textChanged( const QString & text );
60  void on_mCenterSymbolPushButton_clicked();
61  void on_mRendererSettingsButton_clicked();
62  void updateCenterSymbolFromWidget();
63  void cleanUpSymbolSelector( QgsPanelWidget* container );
64  void updateRendererFromWidget();
65 };
66 
67 #endif // QGSPOINTDISPLACEMENTRENDERERWIDGET_H
static unsigned index
virtual QgsFeatureRenderer * renderer()=0
return pointer to the renderer (no transfer of ownership)
virtual void setContext(const QgsSymbolWidgetContext &context)
Sets the context in which the renderer widget is shown, eg the associated map canvas and expression c...
Base class for renderer settings widgets.
Base class for any widget that can be shown as a inline panel.
Contains settings which reflect the context in which a symbol (or renderer) widget is shown...
A renderer that automatically displaces points with the same geographic location. ...
Represents a vector layer which manages a vector based data sets.