http://qt-project.org/doc/qt-5/qwidget.html#keyPressEvent
Note that QKeyEvent starts with isAccepted() == true, so you do not need to call QKeyEvent::accept() - just do not call the base class implementation if you act upon the key.
http://qt-project.org/doc/qt-5/qkeyevent.html#details
A key event contains a special accept flag that indicates whether the receiver will handle the key event. You should call ignore() if the key press or release event is not handled by your widget. A key event is propagated up the parent widget chain until a widget accepts it with accept() or an event filter consumes it. Key events for multimedia keys are ignored by default. You should call accept() if your widget handles those events.
That's a bit confusing. Should I call accept or not? Should I call the base implementation or call ignore if I don't handle it?
The first page reads I don't need to call accept(), the second reads "is propagated up the parent widget chain until a widget accepts it with accept()"
If I call the base version it'll basically call ignore() if it's QWidget. Wouldn't that mean it would return to my keyPressedEvent, return with ignored state, then QWidget's version is called again cause "key event is propagated up to the parent widget"?