mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-20 16:20:52 +01:00
same change for polygons as for other primitives to support Qt5 & Qt6
This commit is contained in:
@@ -66,14 +66,7 @@ void PartPolygon::paint(QPainter *painter, const QStyleOptionGraphicsItem *optio
|
||||
applyStylesToQPainter(*painter);
|
||||
|
||||
QPen t = painter -> pen();
|
||||
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) // ### Qt 6: remove
|
||||
t.setCosmetic(options && options -> levelOfDetail < 1.0);
|
||||
#else
|
||||
#if TODO_LIST
|
||||
#pragma message("@TODO remove code for QT 6 or later")
|
||||
#endif
|
||||
t.setCosmetic(options && options -> levelOfDetailFromTransform(painter->worldTransform()) < 1.0);
|
||||
#endif
|
||||
if (isSelected()) t.setColor(Qt::red);
|
||||
painter -> setPen(t);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user