This is out side of the scope of this forum, since this is basic C++ issue.
In short however, if you call the paintEvent of the mother class(in your case it would be QPushButton:aintEvent()), then you have its functionality too.
But please don't ask basic C++ questions in these forums, as they are meant for specific help with Qt related issue, where C++ (or what ever language you are using with your Qt) knowledge is assumed.
Bookmarks