Rewrite debug output of event classes.

Bring debug formatting in Qt 4 on par with Qt 5.4:
- Introduce functions to return class name and type name by type.
- Add verbose output for DnD, tablet, native gestures and context
  menu, events.

Task-number: QTBUG-38858
Task-number: QTBUG-42344

[ChangeLog][QtGui][QEvent] The debug output for events has
been significantly improved.

Change-Id: I3f11e34c3c9d6a3c6db596be4051b801f00e6153
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
(cherry picked from qtbase/14f9c09542bd6cc19430473da9ce4c68f239ec7d)
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>