39 mainLayout->addWidget( mItemPropertiesWidget );
47 mPolygonStyleButton->registerExpressionContextGenerator( mPolygon );
50 setGuiElementValues();
52 mPolygonStyleButton->registerExpressionContextGenerator( mPolygon );
54 if ( mPolygon->layout() )
62 if ( mItemPropertiesWidget )
76 mPolygon = qobject_cast< QgsLayoutItemPolygon * >( item );
77 mItemPropertiesWidget->
setItem( mPolygon );
82 mPolygonStyleButton->registerExpressionContextGenerator( mPolygon );
84 setGuiElementValues();
89 void QgsLayoutPolygonWidget::setGuiElementValues()
96 whileBlocking( mPolygonStyleButton )->setSymbol( mPolygon->symbol()->clone() );
99 void QgsLayoutPolygonWidget::symbolChanged()
105 mPolygon->setSymbol( mPolygonStyleButton->clonedSymbol<
QgsFillSymbol>() );
106 mPolygon->layout()->undoStack()->endCommand();
A fill symbol type, for rendering Polygon and MultiPolygon geometries.
Layout item for node based polygon shapes.
@ LayoutPolygon
Polygon shape item.
Base class for graphical items within a QgsLayout.
@ UndoShapeStyle
Shape symbol style.
int type() const override
Returns a unique graphics item type identifier.
void changed()
Emitted when the object's properties change.
void layerChanged(QgsVectorLayer *layer)
Emitted when the context's layer is changed.
Interface for master layout type objects, such as print layouts and reports.
QgsSignalBlocker< Object > whileBlocking(Object *object)
Temporarily blocks signals from a QObject while calling a single method from the object.