Closed isf63 closed 3 months ago
I can confirm this is unrelated to themeing by creating a blank theme (mkdir ~/.local/share/lxqt/themes/blank; touch ~/.local/share/lxqt/themes/blank/lxqt-panel.qss
, and then inspecting the button widths with GammaRay. With Maximum button width set to 200px, 2 windows open the widths are: (200, 200) and 3 windows (200, 201, 200).
Yes, that may be a sign of a small miscalculation somewhere. It isn't easy to find where but, fortunately, it hasn't had a serious side effect.
Related to https://github.com/lxqt/lxqt-panel/issues/2083 indirectly.
My wild guess is that, in some line(s) of code, the special property of QRect::right() (see Qt doc's note) may have been ignored, resulting in a one-pixel miscalculation. I already found and fixed one case, but it wasn't related to this report.
OK, the problem wasn't in lxqt-panel but in liblxqt → GridLayout::setGeometry()
. After I changed its strange calculations to what looked reasonable to me, the shifting was gone.
I should check those calculations several times to make sure that I haven't missed anything. Then I'll make a PR. But in short, for a reason unknown to me, an extra one pixel was added in some places without being considered in others. I just removed it for testing.
@isf63 If you use git, please test https://github.com/lxqt/liblxqt/pull/351. The panel should be restarted.
Current Behavior
Taskbar buttons shift slightly when opening or closing windows
Possible Solution
Steps to Reproduce (for bugs)
There is a subtle shift in the buttons position.
Context
Minor UX issue Sometimes displayed eliding is affected
Affects all LXQt themes, except KDE-Plasma for me.
System Information