17 #ifndef QGSLAYOUTOBJECT_H 18 #define QGSLAYOUTOBJECT_H 20 #include "qgis_core.h" 162 void setCustomProperty(
const QString &key,
const QVariant &value );
173 QVariant customProperty(
const QString &key,
const QVariant &defaultValue = QVariant() )
const;
182 void removeCustomProperty(
const QString &key );
190 QStringList customProperties()
const;
222 bool writeObjectPropertiesToElement( QDomElement &parentElement, QDomDocument &document,
const QgsReadWriteContext &context )
const;
232 bool readObjectPropertiesFromElement(
const QDomElement &parentElement,
const QDomDocument &document,
const QgsReadWriteContext &context );
246 static void initPropertyDefinitions();
248 friend class TestQgsLayoutObject;
252 #endif //QGSLAYOUTOBJECT_H
The class is used as a container of context for various read/write operations on other objects...
Layer and style map theme.
QgsObjectCustomProperties mCustomProperties
Custom properties for object.
Exclude item from exports.
QgsPropertyCollection & dataDefinedProperties()
Returns a reference to the object's property collection, used for data defined overrides.
Dummy property with no effect on item.
Number of pages in composition (deprecated)
PropertyValueType
Specifies whether the value returned by a function should be the original, user set value...
Attribute table source layer.
virtual QgsExpressionContext createExpressionContext() const =0
This method needs to be reimplemented in all classes which implement this interface and return an exp...
Scalebar secondary fill color.
QgsPropertyCollection mDataDefinedProperties
Item transparency (deprecated)
Expression contexts are used to encapsulate the parameters around which a QgsExpression should be eva...
QPointer< QgsLayout > mLayout
Page number for item placement.
Base class for layouts, which can contain items such as maps, labels, scalebars, etc.
QMap< int, QgsPropertyDefinition > QgsPropertiesDefinition
Definition of available properties.
Abstract interface for generating an expression context.
QgsCompositionConverter class converts a QGIS 2.x composition to a QGIS 3.x layout.
void setDataDefinedProperties(const QgsPropertyCollection &collection)
Sets the objects's property collection, used for data defined overrides.
Preset paper size for composition.
Paper height (deprecated)
Simple key-value store (keys = strings, values = variants) that supports loading/saving to/from XML i...
A base class for objects which belong to a layout.
A grouped map of multiple QgsProperty objects, each referenced by a integer key value.
virtual void refresh()
Refreshes the object, causing a recalculation of any property overrides.
DataDefinedProperty
Data defined properties for different item types.
const QgsPropertyCollection & dataDefinedProperties() const
Returns a reference to the object's property collection, used for data defined overrides.