qt5base-lts/tests/auto/widgets
Volker Hilsheimer fb8701cb8b QListView: Prevent infinite loop when wrapping text of item with null-icon
If an item in a list view has a null icon, then the decorationSize gets
calculated as -1, -1. The style would then try to wrap the text to a
lineWidth of -1, ending up in an infinite loop in viewItemTextLayout.

To prevent that, don't set the HasDecoration flag of the style option
when the icon is null, and don't fall back ot the decorationSize unless
the flag is set.

Add a test for this particular item configuration. This also fixes the
widget baseline test with styles that don't provide all standard icons.

Pick-to: 6.5
Change-Id: I691db6abede9a9b2ad300f3ee7fbfdae5fb6097f
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: Santhosh Kumar <santhosh.kumar.selvaraj@qt.io>
2023-01-04 13:42:06 +01:00
..
dialogs macOS: Add dialog helper for native message boxes 2022-11-15 20:36:17 +01:00
effects Change the license of all CMakeLists.txt and *.cmake files to BSD 2022-08-23 23:58:42 +02:00
graphicsview QGraphicsView: fix jumping graphic items when dragging out of view 2022-11-26 16:07:15 +02:00
itemviews QListView: Prevent infinite loop when wrapping text of item with null-icon 2023-01-04 13:42:06 +01:00
kernel Skip tst_QWidget::optimizedResizeMove and ..._topLevel on wayland 2023-01-03 19:21:39 +00:00
styles Port from container::count() and length() to size() - V5 2022-11-03 14:59:24 +01:00
util Port from container::count() and length() to size() - V5 2022-11-03 14:59:24 +01:00
widgets tests: skip tst_QComboBox::cancelClosesPopupNotDialog() on Wayland 2023-01-03 12:07:43 +01:00
CMakeLists.txt Change the license of all CMakeLists.txt and *.cmake files to BSD 2022-08-23 23:58:42 +02:00