mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-28 00:17:30 -05:00
parent
230e91c44b
commit
a4147b7a38
@ -287,6 +287,9 @@ double QgsMapCanvasAnnotationItem::scaledSymbolSize() const
|
||||
|
||||
void QgsMapCanvasAnnotationItem::paint( QPainter *painter )
|
||||
{
|
||||
if ( !mAnnotation || !mAnnotation->isVisible() )
|
||||
return;
|
||||
|
||||
QgsRenderContext rc = QgsRenderContext::fromQPainter( painter );
|
||||
rc.setFlag( QgsRenderContext::Antialiasing, true );
|
||||
|
||||
|
@ -2806,11 +2806,14 @@ namespace QgsWms
|
||||
void QgsRenderer::annotationsRendering( QPainter *painter ) const
|
||||
{
|
||||
const QgsAnnotationManager *annotationManager = mProject->annotationManager();
|
||||
QList< QgsAnnotation * > annotations = annotationManager->annotations();
|
||||
const QList< QgsAnnotation * > annotations = annotationManager->annotations();
|
||||
|
||||
QgsRenderContext renderContext = QgsRenderContext::fromQPainter( painter );
|
||||
Q_FOREACH ( QgsAnnotation *annotation, annotations )
|
||||
for ( QgsAnnotation *annotation : annotations )
|
||||
{
|
||||
if ( !annotation || !annotation->isVisible() )
|
||||
continue;
|
||||
|
||||
annotation->render( renderContext );
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user