git-svn-id: svn://db.shs.com.ru/libs@78 a8b55f48-bf90-11e4-a774-851b48703e85
This commit is contained in:
@@ -550,10 +550,19 @@ void BlockBusItem::paint(QPainter * p, const QStyleOptionGraphicsItem * o, QWidg
|
|||||||
QTransform tf;
|
QTransform tf;
|
||||||
tf.translate(sp.x(), sp.y());
|
tf.translate(sp.x(), sp.y());
|
||||||
tf.rotate(-QLineF(sp, ep).angle());
|
tf.rotate(-QLineF(sp, ep).angle());
|
||||||
tf.translate(0., im_bus.height() / 2.);
|
tf.translate(0., -im_bus.height() / 2.);
|
||||||
|
/*
|
||||||
br.setTransform(tf);
|
br.setTransform(tf);
|
||||||
p->setPen(QPen(br, im_bus.height(), Qt::SolidLine, Qt::FlatCap, Qt::BevelJoin));
|
p->setPen(QPen(br, im_bus.height(), Qt::SolidLine, Qt::FlatCap, Qt::BevelJoin));
|
||||||
p->drawLine(sp, ep);
|
p->drawLine(sp, ep);
|
||||||
|
*/
|
||||||
|
p->save();
|
||||||
|
p->setTransform(tf, true);
|
||||||
|
p->setPen(Qt::NoPen);
|
||||||
|
p->setBrush(br);
|
||||||
|
//p->drawLine(QPointF(0., 0.), QPointF(QLineF(sp, ep).length(), 0.));
|
||||||
|
p->drawRect(QRectF(0., 0., QLineF(sp, ep).length(), im_bus.height()));
|
||||||
|
p->restore();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!im_end.isNull()) {
|
if (!im_end.isNull()) {
|
||||||
|
|||||||
Reference in New Issue
Block a user