I have discovered QRubberBand class. I don't know how to use it though, yet.
https://doc.qt.io/qt-5/qrubberband.html