sioyek icon indicating copy to clipboard operation
sioyek copied to clipboard

Weird dragging on text selection after switching to QMainWindow

Open iamkroot opened this issue 1 year ago • 2 comments

After https://github.com/ahrm/sioyek/commit/f7727a8e4e6af18ae631d5a2bfa4db1f1b4d3b39, I'm seeing extremely annoying behavior when selecting text. Essentially, if we drag on the empty portions of the page, instead of snapping the selection to text, it starts dragging the window.

See gif for before/after.

output (higher quality video link)

In the beginning, sioyek is on an old version. I switch to the build from bad commit at around 8 seconds.

Maybe there's a way to opt out of this dragging behavior at the Qt level?

iamkroot avatar May 02 '24 15:05 iamkroot

I think this maybe an interaction of QMainWindow with your window manager because I can't reproduce it on my machines. What window manager are you using here?

ahrm avatar May 02 '24 16:05 ahrm

Hmm I'm using KWin on X11 (will report on Wayland in a bit).

Other than that, I'm also running Kvantum. That has a setting called "Drag from:" with the options "Titlebar", "Menubar", "Menubar and primary toolbar", and "Anywhere". I've set it to "Menubar and primary toolbar".

Will check if it is something to do with Kvantum.

iamkroot avatar May 02 '24 16:05 iamkroot