27 connect( mSpinZIndex, qOverload<int>( &QSpinBox::valueChanged ),
this, [ = ]
29 if ( !mBlockChangedSignal )
32 mSpinZIndex->setClearValue( 0 );
34 connect( mReferenceScaleGroup, &QGroupBox::toggled,
this, [ = ]
36 if ( !mBlockChangedSignal )
41 if ( !mBlockChangedSignal )
44 connect( mCalloutCheckBox, &QCheckBox::toggled,
this, [ = ]
46 if ( !mBlockChangedSignal )
50 connect( mCalloutPropertiesButton, &QToolButton::clicked,
this, &QgsAnnotationItemCommonPropertiesWidget::openCalloutProperties );
57 mSpinZIndex->setValue( item->
zIndex() );
61 mCalloutCheckBox->setChecked( item->
callout() );
70 item->
setCallout( mCallout && mCalloutCheckBox->isChecked() ? mCallout->clone() : nullptr );
78 mReferenceScaleWidget->setShowCurrentScaleButton(
true );
86void QgsAnnotationItemCommonPropertiesWidget::openCalloutProperties()
96 if ( !mBlockChangedSignal )
102 panel->openPanel( widget );
@ SupportsReferenceScale
Item supports reference scale based rendering.
Abstract base class for annotation items which are drawn with QgsAnnotationLayers.
void setUseSymbologyReferenceScale(bool enabled)
Sets whether the annotation item uses a symbology reference scale.
void setZIndex(int index)
Sets the item's z index, which controls the order in which annotation items are rendered in the layer...
bool useSymbologyReferenceScale() const
Returns true if the annotation item uses a symbology reference scale.
void setCallout(QgsCallout *callout)
Sets the item's callout renderer, responsible for drawing item callouts.
void setSymbologyReferenceScale(double scale)
Sets the annotation's symbology reference scale.
virtual Qgis::AnnotationItemFlags flags() const
Returns item flags.
int zIndex() const
Returns the item's z index, which controls the order in which annotation items are rendered in the la...
QgsCallout * callout() const
Returns the item's callout renderer, responsible for drawing item callouts.
double symbologyReferenceScale() const
Returns the annotation's symbology reference scale.
static QgsCalloutRegistry * calloutRegistry()
Returns the application's callout registry, used for managing callout types.
virtual QgsCallout * clone() const =0
Duplicates a callout by creating a deep copy of the callout.
Contains settings which reflect the context in which a symbol (or renderer) widget is shown,...
void setMapCanvas(QgsMapCanvas *canvas)
Sets the map canvas associated with the widget.
QgsMapCanvas * mapCanvas() const
Returns the map canvas associated with the widget.