2016-08-06 11:01:42 +02:00
|
|
|
class QgsGraduatedSymbolRendererWidget : QgsRendererWidget
|
2012-09-24 02:28:15 +02:00
|
|
|
{
|
|
|
|
%TypeHeaderCode
|
2016-08-07 17:33:22 +02:00
|
|
|
#include <qgsgraduatedsymbolrendererwidget.h>
|
2012-09-24 02:28:15 +02:00
|
|
|
%End
|
|
|
|
public:
|
2016-08-06 11:01:42 +02:00
|
|
|
static QgsRendererWidget* create( QgsVectorLayer* layer, QgsStyle* style, QgsFeatureRenderer* renderer ) /Factory/;
|
2012-09-24 02:28:15 +02:00
|
|
|
|
2016-08-06 11:01:42 +02:00
|
|
|
QgsGraduatedSymbolRendererWidget( QgsVectorLayer* layer, QgsStyle* style, QgsFeatureRenderer* renderer );
|
|
|
|
~QgsGraduatedSymbolRendererWidget();
|
2012-09-24 02:28:15 +02:00
|
|
|
|
2016-08-06 11:01:42 +02:00
|
|
|
virtual QgsFeatureRenderer* renderer();
|
2012-09-24 02:28:15 +02:00
|
|
|
|
|
|
|
public slots:
|
|
|
|
void changeGraduatedSymbol();
|
2015-10-07 11:55:34 +11:00
|
|
|
void graduatedColumnChanged( const QString& field );
|
2012-09-24 02:28:15 +02:00
|
|
|
void classifyGraduated();
|
|
|
|
void reapplyColorRamp();
|
2015-03-30 17:48:00 +02:00
|
|
|
void reapplySizes();
|
2012-09-24 02:28:15 +02:00
|
|
|
void rangesDoubleClicked( const QModelIndex & idx );
|
|
|
|
void rangesClicked( const QModelIndex & idx );
|
|
|
|
void changeCurrentValue( QStandardItem * item );
|
|
|
|
|
2015-07-29 11:52:14 +02:00
|
|
|
/** Adds a class manually to the classification*/
|
2012-09-24 02:28:15 +02:00
|
|
|
void addClass();
|
2015-07-29 11:52:14 +02:00
|
|
|
/** Removes currently selected classes */
|
2012-11-18 12:52:26 +01:00
|
|
|
void deleteClasses();
|
2015-07-29 11:52:14 +02:00
|
|
|
/** Removes all classes from the classification*/
|
2013-02-02 17:06:22 +01:00
|
|
|
void deleteAllClasses();
|
2015-07-29 11:52:14 +02:00
|
|
|
/** Toggle the link between classes boundaries */
|
2014-09-20 18:30:12 +12:00
|
|
|
void toggleBoundariesLink( bool linked );
|
2012-09-24 02:28:15 +02:00
|
|
|
|
2014-09-26 14:47:46 +12:00
|
|
|
void labelFormatChanged();
|
2012-09-24 02:28:15 +02:00
|
|
|
|
|
|
|
void showSymbolLevels();
|
|
|
|
|
2013-02-02 17:06:22 +01:00
|
|
|
void rowsMoved();
|
2014-09-26 14:47:46 +12:00
|
|
|
void modelDataChanged();
|
2013-02-02 17:06:22 +01:00
|
|
|
|
2016-01-04 22:51:18 +11:00
|
|
|
void on_mSizeUnitWidget_changed();
|
|
|
|
void on_methodComboBox_currentIndexChanged( int );
|
|
|
|
void refreshRanges( bool reset = false );
|
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
protected:
|
2015-02-03 02:21:52 +01:00
|
|
|
void updateUiFromRenderer( bool updateCount = true );
|
2014-09-24 10:50:54 +12:00
|
|
|
void connectUpdateHandlers();
|
|
|
|
void disconnectUpdateHandlers();
|
2014-09-26 14:47:46 +12:00
|
|
|
bool rowsOrdered();
|
2012-09-24 02:28:15 +02:00
|
|
|
|
|
|
|
void updateGraduatedSymbolIcon();
|
|
|
|
|
2013-02-02 17:06:22 +01:00
|
|
|
//! return a list of indexes for the classes under selection
|
|
|
|
QList<int> selectedClasses();
|
2014-01-26 18:35:21 +01:00
|
|
|
QgsRangeList selectedRanges();
|
2013-02-02 17:06:22 +01:00
|
|
|
|
2012-09-24 02:28:15 +02:00
|
|
|
void changeRangeSymbol( int rangeIdx );
|
|
|
|
void changeRange( int rangeIdx );
|
|
|
|
|
2013-02-02 17:06:22 +01:00
|
|
|
void changeSelectedSymbols();
|
|
|
|
|
2016-08-05 08:09:43 +02:00
|
|
|
QList<QgsSymbol*> selectedSymbols();
|
|
|
|
QgsSymbol* findSymbolForRange( double lowerBound, double upperBound, const QgsRangeList& ranges ) const;
|
2012-09-24 02:28:15 +02:00
|
|
|
void refreshSymbolView();
|
2014-01-26 18:35:21 +01:00
|
|
|
|
|
|
|
void keyPressEvent( QKeyEvent* event );
|
2012-09-24 02:28:15 +02:00
|
|
|
};
|