Don't crash when calculating the implicit width of truncated lines.
authorAndrew den Exter <andrew.den-exter@nokia.com>
Tue, 17 Apr 2012 07:28:50 +0000 (17:28 +1000)
committerQt by Nokia <qt-info@nokia.com>
Tue, 17 Apr 2012 09:06:15 +0000 (11:06 +0200)
commite624c2d9b0940f0abc24ef7685238299fec5c36e
treec711593f566af4112c3ae8836229ec575e5a85e7
parente5c04205903b7c413fe09be321fc4becf60a3c51
Don't crash when calculating the implicit width of truncated lines.

Remember to call beginLayout() on the QTextLayout before creating
lines or the layout data won't be allocated.

Change-Id: Ic344ca376fc25e38c50078135deb02dee3afc4f1
Reviewed-by: Chris Adams <christopher.adams@nokia.com>
Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
src/quick/items/qquicktext.cpp
tests/auto/quick/qquicktext/tst_qquicktext.cpp