How do I create bubble tooltips in Qt?
I am trying to implement bubble tip tooltips in qt with no luck. Even tried to put the css file in qt with the code to create tooltips, but no use. Any methods for creating bubble tooltips in qt widgets?
You can use QBalloonTip
which is an inner class defined in:
-
Qt 5:
QtDir/Src/qtbase/src/widgets/util/qsystemtrayicon_p.h
-
Qt 4:
QtDir/src/gui/utils/util/qsystemtrayicon_p.h
QBalloonTip
inherits QWidget
and is implemented qsystemtrayicon.cpp
in the same directory. It has the following method to show the tip of the balloon:
void QBalloonTip::balloon(const QPoint& pos, int msecs, bool showArrow)
You can modify the source code of this class to have the ball tip you want.