19 #include <QStackedWidget> 21 #include "ui_qgsdualviewbase.h" 41 class GUI_EXPORT
QgsDualView :
public QStackedWidget,
private Ui::QgsDualViewBase
100 bool loadFeatures =
true );
137 void setSelectedOnTop(
bool selectedOnTop );
152 int filteredFeatureCount();
160 void setFilteredFeatures(
const QgsFeatureIds &filteredFeatures );
204 void setSortExpression(
const QString &sortExpression, Qt::SortOrder sortOrder = Qt::AscendingOrder );
209 QString sortExpression()
const;
232 bool saveEditChanges();
234 void openConditionalStyles();
240 void setMultiEditEnabled(
bool enabled );
247 void toggleSearchMode(
bool enabled );
253 void copyCellContent()
const;
259 void cancelProgress( );
267 void displayExpressionChanged(
const QString &expression );
272 void filterChanged();
296 void hideEvent( QHideEvent *event )
override;
300 void featureListAboutToChangeEditSelection(
bool &ok );
307 void featureListCurrentEditSelectionChanged(
const QgsFeature &feat );
309 void previewExpressionBuilder();
311 void previewColumnChanged( QAction *previewAction,
const QString &expression );
313 void viewWillShowContextMenu( QMenu *menu,
const QModelIndex &atIndex );
315 void widgetWillShowContextMenu(
QgsActionMenu *menu,
const QModelIndex &atIndex );
317 void showViewHeaderMenu( QPoint point );
319 void organizeColumns();
321 void tableColumnResized(
int column,
int width );
327 void autosizeColumn();
331 void previewExpressionChanged(
const QString &expression );
333 void onSortColumnChanged();
335 void sortByPreviewExpression();
337 void updateSelectedFeatures();
339 void extentChanged();
346 void featureFormAttributeChanged(
const QString &attribute,
const QVariant &value,
bool attributeChanged );
354 virtual void progress(
int i,
bool &cancel );
360 virtual void finished();
363 void zoomToCurrentFeature();
365 void panToCurrentFeature();
367 void flashCurrentFeature();
369 void rebuildFullLayerCache();
371 void panZoomGroupButtonToggled( QAbstractButton *button,
bool checked );
373 void flashButtonClicked(
bool clicked );
380 void columnBoxInit();
381 void initLayerCache(
bool cacheGeometry );
383 void restoreRecentDisplayExpressions();
384 void saveRecentDisplayExpressions()
const;
385 void setDisplayExpression(
const QString &expression );
386 void insertRecentlyUsedDisplayExpression(
const QString &expression );
387 void updateEditSelectionProgress(
int progress,
int count );
395 QMenu *mPreviewColumnsMenu =
nullptr;
396 QMenu *mPreviewActionMenu =
nullptr;
397 QAction *mLastDisplayExpressionAction =
nullptr;
398 QMenu *mHorizontalHeaderMenu =
nullptr;
400 QPointer< QgsVectorLayer > mLayer =
nullptr;
401 QProgressDialog *mProgressDlg =
nullptr;
403 QString mDisplayExpression;
410 friend class TestQgsDualView;
411 friend class TestQgsAttributeTable;
430 : QAction( name, dualView )
431 , mDualView( dualView )
433 , mFieldIdx( fieldIdx )
443 QModelIndex mFieldIdx;
456 : QAction( name, dualView )
457 , mDualView( dualView )
459 , mFieldIdx( fieldIdx )
468 QModelIndex mFieldIdx;
473 #endif // QGSDUALVIEW_H
Provides a table view of features of a QgsVectorLayer.
QSet< QgsFeatureId > QgsFeatureIds
QgsAttributeTableModel * masterModel() const
Returns the model which has the information about all features (not only filtered) ...
This class contains context information for attribute editor widgets.
QgsAttributeTableView * tableView()
Returns the table view.
ViewMode
The view modes, in which this widget can present information.
QgsAttributeTableMapLayerAction(const QString &name, QgsDualView *dualView, QgsMapLayerAction *action, const QModelIndex &fieldIdx)
The map is zoomed to contained the feature bounding-box.
The feature class encapsulates a single feature including its id, geometry and a list of field/values...
A model backed by a QgsVectorLayerCache which is able to provide feature/attribute information to a Q...
Q_DECLARE_METATYPE(QModelIndex)
Map canvas is a class for displaying all GIS data types on a canvas.
FilterMode
The filter mode defines how the rows should be filtered.
This class wraps a request for features to a vector layer (or directly its vector data provider)...
QgsFeatureIds filteredFeatures()
Gets a list of currently visible feature ids.
FeatureListBrowsingAction
Action on the map canvas when browsing the list of features.
This class caches features of a given QgsVectorLayer.
QgsAttributeTableFilterModel::FilterMode filterMode()
Gets the filter mode.
This is a container for configuration of the attribute table.
Is an interface class to abstract feature selection handling.
Represents a vector layer which manages a vector based data sets.
An action which can run on map layers.
QgsAttributeTableAction(const QString &name, QgsDualView *dualView, QUuid action, const QModelIndex &fieldIdx)
Create a new attribute table action.
This widget is used to show the attributes of a set of features of a QgsVectorLayer.
The map is panned to the center of the feature bounding-box.