qt6-bb10/tests/auto/gui/text
Eskil Abrahamsen Blomfeldt be6c651be4 Fix infinite loop in QTextLayout with setNumColumns()
If the line width is negative, then we might exit the layout
loop before consuming any text, and thus the loop will never
finish. This is a side effect of a change for maximumWidth:
991c056438.

49a63d3759 fixed this issue for
QTextLayout::setFixedSize(), but I forgot to do the same in
the overload of QTextLayout::setNumColumns() which includes
an alignment width and therefore sets the line width in addition
to the column count.

Basically, we just make sure the line width is never negative so
that the width > line.width condition also means the width > 0.

Pick-to: 6.5 6.6 6.7
Fixes: QTBUG-115459
Change-Id: If904bfc64cd74e819a0864db55fa9555073d0781
Reviewed-by: Vladimir Belyavsky <belyavskyv@gmail.com>
Reviewed-by: Lars Knoll <lars@knoll.priv.no>
2024-01-29 17:02:36 +00:00
..
qabstracttextdocumentlayout CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qcssparser tests/auto/*: port Q_FOREACH to ranged-for 2023-08-19 16:29:09 +03:00
qfont QFont::Tag: use new comparison helper macros 2023-12-08 03:18:32 +01:00
qfontcache CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qfontdatabase coretext: Support variable application fonts 2023-10-03 19:25:46 +02:00
qfontmetrics CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qglyphrun Skip mixedScript test on platforms with no Hangul font 2023-11-02 17:41:14 +01:00
qinputcontrol CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qrawfont Adapt QRawFont to use QFont::Tag 2023-10-20 21:37:15 +02:00
qstatictext tst_qstatictext: remove dead code 2023-11-26 12:59:27 +00:00
qsyntaxhighlighter CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qtextblock CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qtextcursor CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qtextdocument Skip 'off-by-one' adjustment in block length during undo operation 2023-12-20 15:01:40 +00:00
qtextdocumentfragment CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qtextdocumentlayout Tests: remove blacklisted CIs no longer available 2023-12-06 22:07:44 +01:00
qtextformat CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qtextimagehandler QTextImageHandler: Use QUrl::toLocalFile to convert to local file name 2024-01-21 09:12:33 +00:00
qtextlayout Fix infinite loop in QTextLayout with setNumColumns() 2024-01-29 17:02:36 +00:00
qtextlist CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qtextmarkdownimporter Avoid detection of heading in tst_QTextMarkdownImporter::thematicBreaks 2024-01-24 14:02:33 -07:00
qtextmarkdownwriter CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qtextobject CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qtextodfwriter CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
qtextpiecetable qtextdocument::insertText: port to QSV 2023-10-05 22:08:45 +03:00
qtextscriptengine tst_QTextScriptEngine: replace QList with const array 2023-08-08 16:03:28 +02:00
qtexttable CMake: Make gui tests standalone projects 2023-07-05 15:09:32 +02:00
CMakeLists.txt Move QZipReader/Writer from QtGui to QtCore 2023-04-26 12:01:05 +02:00