Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-75626

RichText with WordWrap uses small width

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P3: Somewhat important
    • None
    • 5.12.3
    • Quick: Other
    • None
    • All

    Description

      This example produces a small width and many line breaks for Text items with RichText format and WordWrap: 

      import QtQuick 2.9
      import QtQuick.Window 2.2
      
      Window {
        visible: true
        width: 640
        height: 480
        title: qsTr("RichText Wrap")
      
        // Rich Text, Word Wrap, and no explicit width causes line breaks and small text width
        Text {
          text: "This is a rich and wrapped text"
      
          wrapMode: Text.WordWrap
          textFormat: Text.RichText
        }
      }

      With Qt 5.11, all text would remain in a single line for this use case.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            w00t Robin Burchell
            GTDev Günther Teufl
            Votes:
            9 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes