diff options
Diffstat (limited to 'src/quick/items/qquicktext.cpp')
-rw-r--r-- | src/quick/items/qquicktext.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/quick/items/qquicktext.cpp b/src/quick/items/qquicktext.cpp index 7a4027890c..e26ad2769a 100644 --- a/src/quick/items/qquicktext.cpp +++ b/src/quick/items/qquicktext.cpp @@ -940,9 +940,10 @@ QRectF QQuickTextPrivate::setupTextLayout(qreal *const baseline) maxHeight = q->heightValid() ? q->height() : FLT_MAX; // If the width of the item has changed and it's possible the result of wrapping, - // eliding, or scaling has changed do another layout. + // eliding, scaling has changed, or the text is not left aligned do another layout. if ((lineWidth < qMin(oldWidth, naturalWidth) || (widthExceeded && lineWidth > oldWidth)) - && (singlelineElide || multilineElide || canWrap || horizontalFit)) { + && (singlelineElide || multilineElide || canWrap || horizontalFit + || q->effectiveHAlign() != QQuickText::AlignLeft)) { widthExceeded = false; heightExceeded = false; continue; |