Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
4.5.2
-
None
-
Fedora 11 KDE
-
1acffda4dd6e737376a54f9b3775dd3470d5349f (qt/tqtc-qtbase/6.2)
Description
Steps to recreate:
Create a QTabWidget and give but the following as its style sheet:
QTabBar::tab {
}
QTabBar::tab:selected
{ font-weight: bold; }Create at least 2 tabs on the QTabWidget and set the label to one of them to: "ManufacturerManufacturerManufacturer"
When this tab is selected, much of the label is not visible because the bolded text is much wider than the normal text. Each tab needs to either 1) resize itself on each selected, hover, !selected, etc event or 2) The first time it is rendered it needs to check against all (pseudo)-states and size it so the largest one fits.
I realized "ManufacturerManufacturerManufacturer" seems like a frivolous name, but this bug can affect much smaller texts when additional styling is applied. I've excluded the other styling for simplicity.
Attachments
Issue Links
- duplicates
-
QTBUG-8209 QTabBar: Tab size incorrect when using bold font in a style sheet
- Closed
- is duplicated by
-
QTBUG-8209 QTabBar: Tab size incorrect when using bold font in a style sheet
- Closed
For Gerrit Dashboard: QTBUG-6905 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
378084,5 | QTabBar: re-layout when tab size hint depends on selected state | dev | qt/qtbase | Status: MERGED | +2 | 0 |
378303,2 | QTabBar: re-layout when tab size hint depends on selected state | 6.2 | qt/qtbase | Status: MERGED | +2 | 0 |
391487,6 | Stylesheet: Fix tab layout when tab has a font and icons | dev | qt/qtbase | Status: MERGED | +2 | 0 |
393471,2 | Stylesheet: Fix tab layout when tab has a font and icons | 6.3 | qt/qtbase | Status: MERGED | +2 | 0 |
393472,2 | Stylesheet: Fix tab layout when tab has a font and icons | 6.2 | qt/qtbase | Status: MERGED | +2 | 0 |