Am Samstag, 9. Juli 2016 um 18:43:50, schrieb Enrico Forestieri <for...@lyx.org> > On Sat, Jul 09, 2016 at 11:45:37AM +0200, Kornel Benko wrote: > > > Am Samstag, 9. Juli 2016 um 04:09:30, schrieb Enrico Forestieri > > <for...@lyx.org> > > > I came up with the attached patch that solves the issue for me. > > > It requires the Qt5X11Extras module, which is not mandatory, though. > > > The patch simply tries to refresh the timestamp of the selection request. > > > I still get the warning from Qt5 (even if only once), but the paste by the > > > middle mouse button succeeds anyway. Recall that this issue does not occur > > > with a focus-follows-mouse policy. Given that it also does not occur with > > > some applications, I don't know who is to blame for this. > > > > > > The patch is for Qt5 and autotools only (I don't know cmake, sorry). > > > > > > > Attached. > > Thanks, but... > > > diff --git a/CMakeLists.txt b/CMakeLists.txt > > index 76cbdde..e39fc59 100644 > > --- a/CMakeLists.txt > > +++ b/CMakeLists.txt > > @@ -929,6 +929,7 @@ set(QPA_XCB) > > if(Qt5X11Extras_FOUND AND QT_USES_X11) > > # QPA_XCB is only valid if QT5+X11 > > set(QPA_XCB 1) > > + set(HAVE_QT5_X11_EXTRAS 1) > > endif() > > This doesn't strike me as correct. QPA_XCB has to be set when Qt5 > uses X11, independently of the presence of the Qt5X11Extras module. > In the patch I changed this to
I understand that. For me the presence of Qt5X11Extras-module was indication of X11. > -if(Qt5X11Extras_FOUND AND QT_USES_X11) > +if(LYX_USE_QT MATCHES "QT5" AND QT_USES_X11) > # QPA_XCB is only valid if QT5+X11 > set(QPA_XCB 1) > + if(Qt5X11Extras_FOUND) > + set(HAVE_QT5_X11_EXTRAS 1) > + endif() > endif() > > Please, can you also check what has to be done for Qt4? The problem > is that I have to use a X11 function and thus the X11 library should > be added for the final link step, as already done for autotools. Have I overseen HAVE_QT4_X11_EXTRAS in your patch? We check for QX11Info in development/cmake/ConfigureChecks.cmake:231 The class QX11Info is only available if qt4 uses X11. What more do you need? Kornel
signature.asc
Description: This is a digitally signed message part.