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

QQuickIconLabel reports an incorrect baselineOffset

XMLWordPrintable

    • bbd6c9972206eccc4d2872be44db509ef716c351 (qt/qtquickcontrols2/5.12)

      IconLabel's baselineOffset is not aligned with the baseline of its text, this poses problems when using it in a layout with Layout.alignment: Qt.AlignBaseline

      IconLabel is the default contentItem for Button.
      A workaround is to use a custom contentItem.

      See attached picture and code for reproduction.

        1. ButtonBaselineBug.png
          42 kB
          Pierre-Yves Siret
        2. main.qml
          3 kB
          Pierre-Yves Siret
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            mitch_curtis Mitch Curtis
            grecko Pierre-Yves Siret
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes