I'm very curious - are Qt's signals and slots (delegate pattern?) intended only for GUI callbacks, or they are perfectly fine and intended for entire apps? I mean, is it better to split apps into small, self-contained objects (classes) and interconnect them via signals and slots? And if so, what is the recommended way to return a value from a signal (request-like signal that is used to return something), since Qt's signals' return values are ignored?
QT's signals and slots are not intended for returning values from the reciver. They are a strictly one way communication mechanism.
The receiver may actually be in a completely different thread, receiving the signal from a queue, way after the sender emit
call returned.
As for using it for anything other than GUI.. you can use them for wherever it fit, if it fits there. why single out GUI as something special?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With