16 #ifndef QGSRULEBASEDRENDERERV2WIDGET_H
17 #define QGSRULEBASEDRENDERERV2WIDGET_H
26 #include <QAbstractItemModel>
49 virtual Qt::ItemFlags flags(
const QModelIndex &
index )
const override;
50 virtual QVariant data(
const QModelIndex &index,
int role = Qt::DisplayRole )
const override;
51 virtual QVariant headerData(
int section, Qt::Orientation orientation,
52 int role = Qt::DisplayRole )
const override;
53 virtual int rowCount(
const QModelIndex &parent = QModelIndex() )
const override;
54 virtual int columnCount(
const QModelIndex & = QModelIndex() )
const override;
56 virtual QModelIndex
index(
int row,
int column,
const QModelIndex &parent = QModelIndex() )
const override;
58 virtual QModelIndex parent(
const QModelIndex &index )
const override;
61 virtual bool setData(
const QModelIndex & index,
const QVariant & value,
int role = Qt::EditRole )
override;
64 Qt::DropActions supportedDropActions()
const override;
65 QStringList mimeTypes()
const override;
66 QMimeData *mimeData(
const QModelIndexList &indexes )
const override;
67 bool dropMimeData(
const QMimeData *data, Qt::DropAction action,
int row,
int column,
const QModelIndex &parent )
override;
69 bool removeRows(
int row,
int count,
const QModelIndex & parent = QModelIndex() )
override;
76 void updateRule(
const QModelIndex& parent,
int row );
78 void updateRule(
const QModelIndex& index );
79 void removeRule(
const QModelIndex& index );
81 void willAddRules(
const QModelIndex& parent,
int count );
82 void finishedAddingRules();
85 void setFeatureCounts( QMap<QgsRuleBasedRendererV2::Rule*, QgsRuleBasedRendererV2Count> theCountMap );
86 void clearFeatureCounts();
96 #include "ui_qgsrulebasedrendererv2widget.h"
115 void editRule(
const QModelIndex&
index );
117 void countFeatures();
120 void refineRuleScales();
121 void refineRuleCategories();
122 void refineRuleRanges();
124 void setRenderingOrder();
126 void currentRuleChanged(
const QModelIndex& current = QModelIndex(),
const QModelIndex& previous = QModelIndex() );
128 void saveSectionWidth(
int section,
int oldSize,
int newSize );
129 void restoreSectionWidths();
132 void refineRule(
int type );
133 void refineRuleCategoriesGui(
const QModelIndexList& index );
134 void refineRuleRangesGui(
const QModelIndexList& index );
135 void refineRuleScalesGui(
const QModelIndexList& index );
142 void keyPressEvent( QKeyEvent* event )
override;
153 void copy()
override;
154 void paste()
override;
161 #include "ui_qgsrendererrulepropsdialogbase.h"
175 void buildExpression();
176 void accept()
override;
187 #endif // QGSRULEBASEDRENDERERV2WIDGET_H