QGIS API Documentation 3.41.0-Master (af5edcb665c)
Loading...
Searching...
No Matches
qgslayoutattributetablewidget.h
Go to the documentation of this file.
1/***************************************************************************
2 qgslayoutattributetablewidget.h
3 ---------------------------------
4 begin : November 2017
5 copyright : (C) 2017 by Nyall Dawson
6 email : nyall dot dawson at gmail dot com
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 QGSLAYOUTATTRIBUTETABLEWIDGET_H
19#define QGSLAYOUTATTRIBUTETABLEWIDGET_H
20
21// We don't want to expose this in the public API
22#define SIP_NO_FILE
23
24#include "qgis_gui.h"
25#include "ui_qgslayoutattributetablewidgetbase.h"
26#include "qgslayoutitemwidget.h"
27
29class QgsLayoutFrame;
30
38class GUI_EXPORT QgsLayoutAttributeTableWidget : public QgsLayoutItemBaseWidget, public QgsExpressionContextGenerator, private Ui::QgsLayoutAttributeTableWidgetBase
39{
40 Q_OBJECT
41 public:
44
45 void setReportTypeString( const QString &string ) override;
46 void setMasterLayout( QgsMasterLayoutInterface *masterLayout ) override;
48
49 protected:
50 bool setNewItem( QgsLayoutItem *item ) override;
51
52 private:
53 QPointer<QgsLayoutItemAttributeTable> mTable;
54 QPointer<QgsLayoutFrame> mFrame;
55 QgsLayoutItemPropertiesWidget *mItemPropertiesWidget = nullptr;
56
58 void blockAllSignals( bool b );
59
60 void toggleSourceControls();
61
62 void toggleAtlasSpecificControls( bool atlasEnabled );
63
64 private slots:
65 void mRefreshPushButton_clicked();
66 void mAttributesPushButton_clicked();
67 void composerMapChanged( QgsLayoutItem *item );
68 void mMaximumRowsSpinBox_valueChanged( int i );
69 void mMarginSpinBox_valueChanged( double d );
70 void mGridStrokeWidthSpinBox_valueChanged( double d );
71 void mGridColorButton_colorChanged( const QColor &newColor );
72 void mBackgroundColorButton_colorChanged( const QColor &newColor );
73 void headerFontChanged();
74 void contentFontChanged();
75 void mDrawHorizontalGrid_toggled( bool state );
76 void mDrawVerticalGrid_toggled( bool state );
77 void mShowGridGroupCheckBox_toggled( bool state );
78 void mShowOnlyVisibleFeaturesCheckBox_stateChanged( int state );
79 void mFeatureFilterCheckBox_stateChanged( int state );
80 void mFeatureFilterEdit_editingFinished();
81 void mFeatureFilterButton_clicked();
82 void mHeaderHAlignmentComboBox_currentIndexChanged( int index );
83 void mHeaderModeComboBox_currentIndexChanged( int index );
84 void mWrapStringLineEdit_editingFinished();
85 void changeLayer( QgsMapLayer *layer );
86 void mAddFramePushButton_clicked();
87 void mResizeModeComboBox_currentIndexChanged( int index );
88 void mSourceComboBox_currentIndexChanged( int index );
89 void mRelationsComboBox_currentIndexChanged( int index );
90 void mEmptyModeComboBox_currentIndexChanged( int index );
91 void mDrawEmptyCheckBox_toggled( bool checked );
92 void mEmptyMessageLineEdit_editingFinished();
93 void mIntersectAtlasCheckBox_stateChanged( int state );
94 void mUniqueOnlyCheckBox_stateChanged( int state );
95 void mEmptyFrameCheckBox_toggled( bool checked );
96 void mHideEmptyBgCheckBox_toggled( bool checked );
97 void mWrapBehaviorComboBox_currentIndexChanged( int index );
98 void mAdvancedCustomizationButton_clicked();
99 void useConditionalStylingChanged( bool checked );
100
102 void setMaximumNumberOfFeatures( int n );
103
105 void updateGuiElements();
106
107 void atlasToggled();
108
109 void updateRelationsCombo();
110};
111
112#endif // QGSLAYOUTATTRIBUTETABLEWIDGET_H
Abstract interface for generating an expression context.
virtual QgsExpressionContext createExpressionContext() const =0
This method needs to be reimplemented in all classes which implement this interface and return an exp...
Expression contexts are used to encapsulate the parameters around which a QgsExpression should be eva...
A widget for configuring layout attribute table items.
Base class for frame items, which form a layout multiframe item.
A layout table subclass that displays attributes from a vector layer.
A base class for property widgets for layout items.
virtual bool setNewItem(QgsLayoutItem *item)
Attempts to update the widget to show the properties for the specified item.
virtual void setMasterLayout(QgsMasterLayoutInterface *masterLayout)
Sets the master layout associated with the item.
virtual void setReportTypeString(const QString &string)
Sets the string to use to describe the current report type (e.g.
A widget for controlling the common properties of layout items (e.g.
Base class for graphical items within a QgsLayout.
Base class for all map layer types.
Definition qgsmaplayer.h:76
Interface for master layout type objects, such as print layouts and reports.