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

QTextLayout places soft hypnens out of text boundaries

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: P3: Somewhat important P3: Somewhat important
    • 5.15.0 Beta2
    • 5.1.1, 5.2.0
    • GUI: Text handling
    • None
    • Ubuntu 13.10, Windows 7
    • bd3c82f8db4391fc1d6d3338827356143fd598dd (qt/qtbase/5.14)

      QTextLayout carefully considers soft hyphens to understand where to wrap the line. But their size is considered zero at alignment stage so hyphens brakes out of text boundaries with Qt::AlignJustify.

      Example qml file and it's screenshot produced by qmlscene are attached.
      Behavior is reproduced even if QTextLayout is used directly, so it's not QTextDocument's bug.

        1. colorpicker.qml
          1 kB
          Ruslan Nigmatullin
        2. h_1388776944_5522810_2e644683f0.png
          90 kB
          Ruslan Nigmatullin
        For Gerrit Dashboard: QTBUG-35940
        # Subject Branch Project Status CR V

            allan.jensen Allan Sandfeld Jensen
            elessar Ruslan Nigmatullin
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes