[Interest] Creating a pop-up window with pointer arrow

Joey Kleingers joey.kleingers at bluequartz.net
Tue Aug 29 14:45:57 CEST 2017


Hello,

I am trying to create a pop-up window in my Qt application that allows me
to input some data.  The user has to press a button to make the pop-up
window appear.  I want the pop-up window to have an arrow attached to it
that points back to this button, but I am not sure how to create that.  The
screenshot below shows the arrow that I want to create.


Currently, I have a QWidget that has the *Qt::FramelessWindowHint* and
*Qt::Popup* window flags set and shows itself whenever the corresponding
button is pressed.  I have been going down the route of setting the left
margin of the QWidget to some pixel value, and then trying to find a way to
make the margin transparent so that I can draw my arrow in it.  However, I
feel that this may not be the correct approach to this problem.

Is there a better way of doing this?

Thanks,
Joey Kleingers
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20170829/7ed5c798/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Screen Shot 2017-08-29 at 8.26.54 AM.png
Type: image/png
Size: 9949 bytes
Desc: not available
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20170829/7ed5c798/attachment.png>


More information about the Interest mailing list