Additional check for clipboards find buffer support - otherwise Qt complains with unsupported clipboard mode

This commit is contained in:
Stephan Witt 2021-02-14 22:18:07 +01:00
parent 5a58ca6576
commit d65e7a8c87

View File

@ -554,7 +554,9 @@ void GuiClipboard::setFindBuffer(docstring const & text)
{ {
LYXERR(Debug::CLIPBOARD, "new findbuffer: " << text); LYXERR(Debug::CLIPBOARD, "new findbuffer: " << text);
Clipboard::setFindBuffer(text); Clipboard::setFindBuffer(text);
qApp->clipboard()->setText(toqstr(text), QClipboard::FindBuffer); if(qApp->clipboard()->supportsFindBuffer()) {
qApp->clipboard()->setText(toqstr(text), QClipboard::FindBuffer);
}
} }