0
0
mirror of https://github.com/fralx/LimeReport.git synced 2024-12-25 00:54:39 +03:00

ShapeItem has been fixed

This commit is contained in:
Arin Alexander 2019-06-27 23:23:05 +03:00
parent 69369e3b0c
commit 71256ccef6

View File

@ -83,6 +83,7 @@ void ShapeItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option,
QPen pen(m_shapeColor); QPen pen(m_shapeColor);
pen.setWidthF(m_lineWidth); pen.setWidthF(m_lineWidth);
pen.setStyle(m_penStyle); pen.setStyle(m_penStyle);
pen.setJoinStyle(Qt::MiterJoin);
painter->setPen(pen); painter->setPen(pen);
QBrush brush(m_shapeBrushColor,m_shapeBrushType); QBrush brush(m_shapeBrushColor,m_shapeBrushType);
brush.setTransform(painter->worldTransform().inverted()); brush.setTransform(painter->worldTransform().inverted());
@ -102,7 +103,7 @@ void ShapeItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option,
painter->drawEllipse(rect()); painter->drawEllipse(rect());
break; break;
case Rectangle: case Rectangle:
if (m_cornerRadius!=0){ if (m_cornerRadius != 0){
painter->setRenderHint(QPainter::Antialiasing); painter->setRenderHint(QPainter::Antialiasing);
painter->drawRoundedRect(rect(),m_cornerRadius,m_cornerRadius); painter->drawRoundedRect(rect(),m_cornerRadius,m_cornerRadius);
} else { } else {