Skip to content
Permalink
Browse files
fix code formatting
  • Loading branch information
troopa81 authored and github-actions committed Sep 14, 2021
1 parent 816757d commit 736d67756c9e33bfc2fbb70e8f8036a5593b3196
Showing with 4 additions and 4 deletions.
  1. +4 −4 src/core/qgsmapsettings.cpp
@@ -380,10 +380,10 @@ QPolygonF QgsMapSettings::visiblePolygon() const
const QSize &sz = outputSize();
const QgsMapToPixel &m2p = mapToPixel();

poly << m2p.toMapCoordinates( 0.0, 0.0 ).toQPointF();
poly << m2p.toMapCoordinates( 0.0, 0.0 ).toQPointF();
poly << m2p.toMapCoordinates( static_cast<double>( sz.width() ), 0.0 ).toQPointF();
poly << m2p.toMapCoordinates( static_cast<double>( sz.width() ), static_cast<double>( sz.height() ) ).toQPointF();
poly << m2p.toMapCoordinates( 0.0, static_cast<double>( sz.height() ) ).toQPointF();
poly << m2p.toMapCoordinates( 0.0, static_cast<double>( sz.height() ) ).toQPointF();

return poly;
}
@@ -402,10 +402,10 @@ QPolygonF QgsMapSettings::visiblePolygonWithBuffer() const
const double mapUnitsPerPixel = mExtent.width() / sz.width();
const double buffer = mExtentBuffer / mapUnitsPerPixel;

poly << m2p.toMapCoordinates( -buffer, -buffer ).toQPointF();
poly << m2p.toMapCoordinates( -buffer, -buffer ).toQPointF();
poly << m2p.toMapCoordinates( static_cast<double>( sz.width() + buffer ), -buffer ).toQPointF();
poly << m2p.toMapCoordinates( static_cast<double>( sz.width() + buffer ), static_cast<double>( sz.height() + buffer ) ).toQPointF();
poly << m2p.toMapCoordinates( -buffer, static_cast<double>( sz.height() + buffer ) ).toQPointF();
poly << m2p.toMapCoordinates( -buffer, static_cast<double>( sz.height() + buffer ) ).toQPointF();

return poly;
}

0 comments on commit 736d677

Please sign in to comment.