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

doc: QFontMetrics::elidedText(...) does not work as expected for ElideNone

    XMLWordPrintable

Details

    • e7507d6cb (dev), 6680b8a81 (6.5), b66fc29fb (6.6), 68dcabd58 (tqtc/lts-5.15), 11af8ebb4 (tqtc/lts-6.2)

    Description

      Issue: QFontMetrics::elidedText(myString, Qt::ElideNone, myWidth) returns myString (i.e., unchanged), even if myString does not fit into myWidth (code works fine with Qt::ElideRight).
      Expected return value: truncated myString, so that it just fills myWidth (without ellipsis appended).
      Solution: either change/correct the implementation. Or, if this is intentional, please clarify in the documentation that Qt::ElideNone does not only prevent an ellipsis to be appended, but disables string clipping altogether.

      Attachments

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

        Activity

          People

            esabraha Eskil Abrahamsen Blomfeldt
            al__ Andreas
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes