From 91a75f6f01fd875d56a6988957c1e64a885757f3 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Tue, 16 May 2017 15:19:27 +0300 Subject: [PATCH] Fix layout internal path support of pen style. --HG-- branch : develop --- src/libs/vlayout/vlayoutpiecepath.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/libs/vlayout/vlayoutpiecepath.cpp b/src/libs/vlayout/vlayoutpiecepath.cpp index f9df90469..c2fe0a842 100644 --- a/src/libs/vlayout/vlayoutpiecepath.cpp +++ b/src/libs/vlayout/vlayoutpiecepath.cpp @@ -72,11 +72,7 @@ QPainterPath VLayoutPiecePath::GetPainterPath() const QPainterPath path; if (not d->m_points.isEmpty()) { - path.moveTo(d->m_points.at(0)); - for (qint32 j = 1; j < d->m_points.count(); ++j) - { - path.lineTo(d->m_points.at(j)); - } + path.addPolygon(QPolygonF(d->m_points)); path.setFillRule(Qt::WindingFill); } return path;