Event system
In Qt, events represent things that have happened within an application or a user activity that the application needs to know about. In Qt, events are the objects derived from an abstract QEvent class. Events can be received and handled by any instance of a QObject subclass, but they are especially relevant to widgets.
Whenever an event occurs, an appropriate QEvent subclass instance gets constructed and gives its possession to a particular instance of QObject (or any relevant subclass) by calling its event() function. This function does not handle the event itself; based on the type of event delivered, it calls an event handler for that specific type of event and sends a response based on whether the event was accepted or ignored. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access