Chatterino / chatterino2

Chat client for https://twitch.tv
MIT License
1.97k stars 442 forks source link

Dragging tab across lines may cause empty space between tabs #5450

Open jupjohn opened 3 weeks ago

jupjohn commented 3 weeks ago

Checklist

Describe your issue

While I haven't found a way to replicate this issue, here's my rough memory of how I caused it:

  1. Have multiple lines of tabs
  2. Drag the first tab on the second row up into the first row (unsure if it was left or right of the first row's first tab)
  3. Maybe drag the tab back down to the second row in the same movement
  4. First row's first tab is now pushed out by a tab width???

Screenshots

God I wish I had the sense to screenshot instead of try to reproduce straight away, but I did not... so here's an artistic rendition of the before & after:

Before: image

After: image

OS and Chatterino Version

Chatterino 2.5.1 (commit d2316af70) built with Qt 6.7.1 Running on Arch Linux, kernel: 6.9.3-zen1-1-zen

8thony commented 3 weeks ago

Can reproduce chatterino Chatterino Nightly 2.5.1 (commit 25284fc7) Qt 6.7.1 Running on Windows 10

kornes commented 3 weeks ago

https://github.com/Chatterino/chatterino2/blob/25284fc7034f143966b98917ff4a31f0e540b1e0/src/widgets/helper/NotebookTab.cpp#L415-L418 early return i added recently seems to be a reason, removing it masks the issue and it works as before. Notebook layouting needs some love and refactoring which i dont have time to commit to, so for now suggest to just remove above change.