I have an instance of QClipboard and I want to shift data to it whenever user clicks somewhere in the Application. It seems like there are sometimes performance issues with QClipboard which causes the application to freeze because data gets put on OS clipboard of linux.
QClipboard* clipboard = QApplication::clipboard();
clipboard->setText(QString("Glorious Text"), QClipboard::Clipboard);
It does not happen every time but every fifth or sixth click it freezes for some seconds. So I can not really reproduce properly.
https://www.medo64.com/2019/12/copy-to-clipboard-in-qt/ solved it for me.