Basically I'm trying to draw a border around my frameless window. It's size is 550 and 407. I create my QPainter then my lines and in the end I'm trying to draw them.
def draw_border(self):
painter = QPainter()
painter.begin(self)
pen = QPen(QColor(255, 1, 1))
painter.setPen(pen)
left = QLine(0, 0, 0, 407)
bottom = QLine(0, 407, 550, 407)
right = QLine(550, 407, 550, 0)
painter.drawLine(left)
painter.drawLine(bottom)
painter.drawLine(right)
painter.end()
I expect to have three lines: left, right and bottom, but instead nothing happens.