qt6-bb10/tests/auto/widgets/styles
Volker Hilsheimer 55433f90af Stylesheet: Fix tab layout when tab has a font and icons
Amends e3b2b12a91, which made the
style sheet calculate the font-dependent text size, but didn't
add the space needed for the close button or a tab icon.

QTabBar's layout code already adds the space needed for icons
and margins to the size; so instead of overwriting that size,
subtract the size needed by the normal font, and then add the
size needed for the font form the style rule, considering both
vertical and horizontal tab bars.

Fix the test case to style only one tab rather than the entire
tab bar, otherwise the font is applied to the entire tab bar,
and not just to a specific tab, which is the style sheet style
code in question.

Pick-to: 6.2 6.3
Task-number: QTBUG-6905
Change-Id: Ieed0ba146a32e81229419adecaf41f467cfd5959
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2022-02-02 07:10:12 +01:00
..
qmacstyle macOS: make the slider knob big enough for BigSur and Monterey 2021-11-15 09:30:25 +01:00
qstyle Remove the qmake project files 2021-01-07 15:32:28 +01:00
qstyleoption Remove the qmake project files 2021-01-07 15:32:28 +01:00
qstylesheetstyle Stylesheet: Fix tab layout when tab has a font and icons 2022-02-02 07:10:12 +01:00
CMakeLists.txt CMake: Regenerate subdir test projects 2020-07-09 09:38:39 +02:00