15 #ifndef QGSPROPERTYOVERRIDEBUTTON_H 16 #define QGSPROPERTYOVERRIDEBUTTON_H 24 #include <QToolButton> 53 Q_PROPERTY( QString usageInfo READ usageInfo WRITE setUsageInfo )
54 Q_PROPERTY(
bool active READ isActive WRITE setActive )
74 void init(
int propertyKey,
78 bool auxiliaryStorageEnabled = false );
88 void init(
int propertyKey,
92 bool auxiliaryStorageEnabled = false );
102 void init(
int propertyKey,
106 bool auxiliaryStorageEnabled = false );
123 int propertyKey()
const {
return mPropertyKey; }
128 bool isActive()
const {
return mProperty && mProperty.isActive(); }
153 void setUsageInfo(
const QString &info ) { mUsageInfo = info; updateGui(); }
174 void registerCheckedWidget( QWidget *widget,
bool natural =
true );
181 void registerEnabledWidget( QWidget *widget,
bool natural =
true );
188 void registerVisibleWidget( QWidget *widget,
bool natural =
true );
194 void registerExpressionWidget( QWidget *widget );
211 void registerLinkedWidget( QWidget *widget );
218 void updateFieldLists();
232 void setActive(
bool active );
238 void aboutToShowMenu();
239 void menuActionTriggered( QAction *action );
249 void activated(
bool isActive );
252 void createAuxiliaryField();
255 void mouseReleaseEvent( QMouseEvent *event )
override;
259 void showDescriptionDialog();
260 void showExpressionDialog();
261 void showAssistant();
268 void setActivePrivate(
bool active );
271 int mPropertyKey = -1;
275 QStringList mFieldNameList;
276 QStringList mFieldTypeList;
278 QString mExpressionString;
281 QMenu *mDefineMenu =
nullptr;
282 QAction *mActionDataTypes =
nullptr;
283 QMenu *mFieldsMenu =
nullptr;
284 QMenu *mVariablesMenu =
nullptr;
285 QAction *mActionVariables =
nullptr;
286 QMenu *mColorsMenu =
nullptr;
287 QAction *mActionColors =
nullptr;
289 QAction *mActionActive =
nullptr;
290 QAction *mActionDescription =
nullptr;
291 QAction *mActionExpDialog =
nullptr;
292 QAction *mActionExpression =
nullptr;
293 QAction *mActionPasteExpr =
nullptr;
294 QAction *mActionCopyExpr =
nullptr;
295 QAction *mActionClearExpr =
nullptr;
296 QAction *mActionAssistant =
nullptr;
297 QAction *mActionCreateAuxiliaryField =
nullptr;
302 QString mDataTypesString;
303 QString mInputDescription;
304 QString mFullDescription;
314 SiblingExpressionText,
319 SiblingWidget(
const QPointer<QWidget> &widgetPointer, SiblingType siblingType,
bool natural =
true )
320 : mWidgetPointer( widgetPointer )
321 , mSiblingType( siblingType )
322 , mNatural( natural )
324 QPointer<QWidget> mWidgetPointer;
325 SiblingType mSiblingType;
328 QList< SiblingWidget > mSiblingWidgets;
333 bool mAuxiliaryStorageEnabled =
false;
335 std::shared_ptr< QgsSymbol > mSymbol;
340 void updateSiblingWidgets(
bool state );
343 #endif // QGSPROPERTYOVERRIDEBUTTON_H
Abstract base class for all rendered symbols.
Map canvas is a class for displaying all GIS data types on a canvas.
Abstract base class for QgsPropertyCollection like objects.
A store for object properties.
Definition for a property.
QMap< int, QgsPropertyDefinition > QgsPropertiesDefinition
Definition of available properties.
Abstract interface for generating an expression context.
DataType
Valid data types required by property.
Property requires a string value.
Represents a vector layer which manages a vector based data sets.