From a6cf88aa926c1e0f27ded5db8a603595c7a8afea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20T=C5=AFma?= Date: Thu, 22 Feb 2018 00:50:45 +0100 Subject: [PATCH] Fixed visual artefacts on transparent tiles --- src/GUI/mapview.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/GUI/mapview.cpp b/src/GUI/mapview.cpp index bbf9033c..2af7a47d 100644 --- a/src/GUI/mapview.cpp +++ b/src/GUI/mapview.cpp @@ -761,17 +761,14 @@ void MapView::setBackgroundColor(const QColor &color) void MapView::drawBackground(QPainter *painter, const QRectF &rect) { + painter->fillRect(rect, _backgroundColor); + if (_showMap) { QRectF ir = rect.intersected(_map->bounds()); - - if (_opacity < 1.0 || ir != rect) - painter->fillRect(rect, _backgroundColor); if (_opacity < 1.0) painter->setOpacity(_opacity); - _map->draw(painter, ir); - } else - painter->fillRect(rect, _backgroundColor); + } } void MapView::resizeEvent(QResizeEvent *event)