Skip to content

Commit

Permalink
Draw component port as filled square when it has only one connection
Browse files Browse the repository at this point in the history
This is a fix of regression introduced in 4e9e968, the problem
is described in #818
  • Loading branch information
wawuwo authored and ra3xdh committed Jul 8, 2024
1 parent 215d446 commit ef0a4c8
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions qucs/node.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,11 @@ void Node::paint(QPainter* painter) const {
return;

case 2:
if (Connections.getFirst()->Type == isWire) {
if (Connections.getLast()->Type == isWire) {
if (Connections.getFirst()->Type == isWire && Connections.getLast()->Type == isWire) {
painter->restore();
return;
}
painter->fillRect(cx-2, cy-2, 4, 4, Qt::darkBlue);
}
painter->fillRect(cx-2, cy-2, 4, 4, Qt::darkBlue);
break;

default:
Expand Down

0 comments on commit ef0a4c8

Please sign in to comment.