Jun-30-2022, 06:24 PM
Hey, I have main window and if I click on button then second window will open. In second window I will have buttons and text fields on the left and one plot on the right side. This is my code now:
How to add plot on the right side of this window?
Circle:
class SecondWindow(QWidget): def __init__(self): super().__init__() self.setMinimumSize(600,300) self.setWindowTitle("Second Window") self.label1 = QLabel("Value1: ", self) self.label1.setGeometry(20, 20, 150, 20) self.edit1 = QLineEdit("", self) self.edit1.setGeometry(160, 20, 50, 20)If I add code for circle (below) nothing happened.
How to add plot on the right side of this window?
Circle:
figure, axes = plt.subplots() Drawing_uncolored_circle = plt.Circle( (0.6, 0.6 ), 0.3 ,fill = False ) axes.set_aspect( 1 ) axes.add_artist( Drawing_uncolored_circle ) plt.title( 'Circle' ) plt.draw()Thanks