Signal and Slot

Dear Martin,

I am just done watching the Signal, Slots & Events video and done reading the Signals and Slots chapter on your PySide2 ebook. The sample code below is from your video

self.windowTitleChanged.connect(self.onWindowTitleChange)

def onWindowTitleChange(self, s):   # <--- "s" ??
   print(s)

How do you know that the signal is also passing along a string variable s in this case? There are so many type of signals in Qt (pressed, released, drag, move…etc), how do we know each signal is passing along what-else when it is triggered? How do we find out?

Thanks

You can find your answers here: QWindow — Qt for Python

I think that in this case the signal emits only one unicode parameter.

ROb

1 Like