19#include <QStackedWidget> 
   21#include "ui_qgsdualviewbase.h" 
   44class GUI_EXPORT 
QgsDualView : 
public QStackedWidget, 
private Ui::QgsDualViewBase
 
   80    Q_ENUM( FeatureListBrowsingAction )
 
  105               bool loadFeatures = 
true, 
bool showFirstFeature = 
true );
 
  113    void setView( ViewMode view );
 
  120    ViewMode view() 
const;
 
  142    void setSelectedOnTop( 
bool selectedOnTop );
 
  157    int filteredFeatureCount();
 
  166    Q_DECL_DEPRECATED 
void setFilteredFeatures( 
const QgsFeatureIds &filteredFeatures );
 
  218    void setSortExpression( 
const QString &sortExpression, Qt::SortOrder sortOrder = Qt::AscendingOrder );
 
  223    QString sortExpression() 
const;
 
  253    bool saveEditChanges();
 
  255    void openConditionalStyles();
 
  261    void setMultiEditEnabled( 
bool enabled );
 
  268    void toggleSearchMode( 
bool enabled );
 
  274    void copyCellContent() 
const;
 
  280    void cancelProgress( );
 
  290    void parentFormValueChanged( 
const QString &attribute, 
const QVariant &value );
 
  327    void hideEvent( QHideEvent *event ) 
override;
 
  331    void featureListAboutToChangeEditSelection( 
bool &ok );
 
  338    void featureListCurrentEditSelectionChanged( 
const QgsFeature &feat );
 
  340    void previewExpressionBuilder();
 
  342    void previewColumnChanged( QAction *previewAction, 
const QString &expression );
 
  344    void viewWillShowContextMenu( QMenu *menu, 
const QModelIndex &atIndex );
 
  346    void widgetWillShowContextMenu( 
QgsActionMenu *menu, 
const QModelIndex &atIndex );
 
  348    void showViewHeaderMenu( QPoint point );
 
  350    void organizeColumns();
 
  352    void tableColumnResized( 
int column, 
int width );
 
  358    void resizeAllColumns();
 
  360    void autosizeColumn();
 
  362    void autosizeAllColumns();
 
  364    void previewExpressionChanged( 
const QString &expression );
 
  366    void onSortColumnChanged();
 
  368    void updateSelectedFeatures();
 
  369    void updateEditedAddedFeatures();
 
  371    void extentChanged();
 
  378    void featureFormAttributeChanged( 
const QString &attribute, 
const QVariant &value, 
bool attributeChanged );
 
  386    virtual void progress( 
int i, 
bool &cancel );
 
  392    virtual void finished();
 
  395    void zoomToCurrentFeature();
 
  397    void panToCurrentFeature();
 
  399    void flashCurrentFeature();
 
  401    void rebuildFullLayerCache();
 
  403    void panZoomGroupButtonToggled( QAbstractButton *button, 
bool checked );
 
  405    void flashButtonClicked( 
bool clicked );
 
  407    void filterError( 
const QString &errorMessage );
 
  416    void initAttributeForm( 
const QgsFeature &feature );
 
  421    void columnBoxInit();
 
  422    void initLayerCache( 
bool cacheGeometry );
 
  424    void restoreRecentDisplayExpressions();
 
  425    void saveRecentDisplayExpressions() 
const;
 
  426    void setDisplayExpression( 
const QString &expression );
 
  427    void insertRecentlyUsedDisplayExpression( 
const QString &expression );
 
  428    void updateEditSelectionProgress( 
int progress, 
int count );
 
  431    void setBrowsingAutoPanScaleAllowed( 
bool allowed );
 
  442    QMenu *mPreviewColumnsMenu = 
nullptr;
 
  443    QMenu *mPreviewActionMenu = 
nullptr;
 
  444    QAction *mLastDisplayExpressionAction = 
nullptr;
 
  445    QMenu *mHorizontalHeaderMenu = 
nullptr;
 
  447    QPointer< QgsVectorLayer > mLayer = 
nullptr;
 
  448    QProgressDialog *mProgressDlg = 
nullptr;
 
  450    QString mDisplayExpression;
 
  454    bool mBrowsingAutoPanScaleAllowed = 
true;
 
  455    ViewMode mPreviousView = AttributeTable;
 
  457    friend class TestQgsDualView;
 
  458    friend class TestQgsAttributeTable;
 
  477      : QAction( name, dualView )
 
  478      , mDualView( dualView )
 
  480      , mFieldIdx( fieldIdx )
 
  490    QModelIndex mFieldIdx;
 
  503      : QAction( name, dualView )
 
  504      , mDualView( dualView )
 
  506      , mFieldIdx( fieldIdx )
 
  515    QModelIndex mFieldIdx;
 
This class contains context information for attribute editor widgets.
 
QgsAttributeTableAction(const QString &name, QgsDualView *dualView, QUuid action, const QModelIndex &fieldIdx)
Create a new attribute table action.
 
This is a container for configuration of the attribute table.
 
FilterMode
The filter mode defines how the rows should be filtered.
 
QgsAttributeTableMapLayerAction(const QString &name, QgsDualView *dualView, QgsMapLayerAction *action, const QModelIndex &fieldIdx)
 
A model backed by a QgsVectorLayerCache which is able to provide feature/attribute information to a Q...
 
Provides a table view of features of a QgsVectorLayer.
 
This widget is used to show the attributes of a set of features of a QgsVectorLayer.
 
void showContextMenuExternally(QgsActionMenu *menu, QgsFeatureId fid)
Emitted when selecting context menu on the feature list to create the context menu individually.
 
ViewMode
The view modes, in which this widget can present information.
 
QgsAttributeTableFilterModel::FilterMode filterMode()
Gets the filter mode.
 
QgsFeatureIds filteredFeatures()
Gets a list of currently visible feature ids.
 
void filterChanged()
Emitted whenever the filter changes.
 
QgsAttributeTableView * tableView()
Returns the table view.
 
void formModeChanged(QgsAttributeEditorContext::Mode mode)
Emitted when the form changes mode.
 
FeatureListBrowsingAction
Action on the map canvas when browsing the list of features.
 
@ PanToFeature
The map is panned to the center of the feature bounding-box.
 
@ ZoomToFeature
The map is zoomed to contained the feature bounding-box.
 
void filterExpressionSet(const QString &expression, QgsAttributeForm::FilterType type)
Emitted when a filter expression is set using the view.
 
void displayExpressionChanged(const QString &expression)
Emitted whenever the display expression is successfully changed.
 
QgsAttributeTableModel * masterModel() const
Returns the model which has the information about all features (not only filtered)
 
Expression contexts are used to encapsulate the parameters around which a QgsExpression should be eva...
 
Class for parsing and evaluation of expressions (formerly called "search strings").
 
This class wraps a request for features to a vector layer (or directly its vector data provider).
 
The feature class encapsulates a single feature including its unique ID, geometry and a list of field...
 
Is an interface class to abstract feature selection handling.
 
Map canvas is a class for displaying all GIS data types on a canvas.
 
An action which can run on map layers The class can be used in two manners:
 
This class caches features of a given QgsVectorLayer.
 
Represents a vector layer which manages a vector based data sets.
 
Q_DECLARE_METATYPE(QModelIndex)
 
QSet< QgsFeatureId > QgsFeatureIds
 
qint64 QgsFeatureId
64 bit feature ids negative numbers are used for uncommitted/newly added features
 
QList< int > QgsAttributeList