Removed vertical lines for single byte annotation items
This commit is contained in:
@@ -70,26 +70,29 @@ void AnnotationItem::paint(QPainter* painter, const QStyleOptionGraphicsItem* op
|
|||||||
);
|
);
|
||||||
|
|
||||||
painter->setPen(lineColor);
|
painter->setPen(lineColor);
|
||||||
painter->drawLine(QLine(
|
|
||||||
ByteItem::WIDTH / 2,
|
|
||||||
verticalLineYStart,
|
|
||||||
ByteItem::WIDTH / 2,
|
|
||||||
verticalLineYEnd
|
|
||||||
));
|
|
||||||
|
|
||||||
painter->drawLine(QLine(
|
if (this->size > 1) {
|
||||||
this->width - (ByteItem::WIDTH / 2),
|
painter->drawLine(QLine(
|
||||||
verticalLineYStart,
|
ByteItem::WIDTH / 2,
|
||||||
this->width - (ByteItem::WIDTH / 2),
|
verticalLineYStart,
|
||||||
verticalLineYEnd
|
ByteItem::WIDTH / 2,
|
||||||
));
|
verticalLineYEnd
|
||||||
|
));
|
||||||
|
|
||||||
painter->drawLine(QLine(
|
painter->drawLine(QLine(
|
||||||
ByteItem::WIDTH / 2,
|
this->width - (ByteItem::WIDTH / 2),
|
||||||
verticalLineYEnd,
|
verticalLineYStart,
|
||||||
(ByteItem::WIDTH / 2) + (this->width - ByteItem::WIDTH),
|
this->width - (ByteItem::WIDTH / 2),
|
||||||
verticalLineYEnd
|
verticalLineYEnd
|
||||||
));
|
));
|
||||||
|
|
||||||
|
painter->drawLine(QLine(
|
||||||
|
ByteItem::WIDTH / 2,
|
||||||
|
verticalLineYEnd,
|
||||||
|
(ByteItem::WIDTH / 2) + (this->width - ByteItem::WIDTH),
|
||||||
|
verticalLineYEnd
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
painter->drawLine(QLine(
|
painter->drawLine(QLine(
|
||||||
this->width / 2,
|
this->width / 2,
|
||||||
|
|||||||
Reference in New Issue
Block a user