Details
-
Bug
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
5.11.2
-
None
Description
After changing the format using `setDisplayFormat`, the widget isn't resized properly.
```
auto dte = new QDateTimeEdit()
dte->setDateTimeFormat("yyyy-MM-dd hh:mm:ss"); // ok!
...
dte->setDateTimeFormat("yyyy-MM-dd"); // ok! gets smaller
...
dte->setDateTimeFormat("yyyy-MM-dd hh:mm:ss"); // failure! keeps small size.
```
This is the `sizeHint()` for the three fictive calls above:
```
288,50
175,50
175,50
```
As you can see, the size hint gets smaller, but not larger for unknown reasons.