Details
-
Bug
-
Resolution: Done
-
P2: Important
-
4.5.0
-
None
-
515f6a8c3dbe382bbb4f84f758a61c719143d8a6
Description
1. Create a QCheckBox without any text.
2. Place check box in a layout (vertical or grid) and make it center aligned.
3. Add some other items into the layout (QLabel for example).
Result: The check box width (size hint) includes text padding on the right even when the text is empty. This will cause the check box to not be properly centered compared to other items in the layout. The fix is in the sizeHint() code; the text width should be ignored if text() is empty.