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

QPushButton has hardcoded spacing between icon and text

XMLWordPrintable

      QPushButton doesn't provide API or stylesheet properties to set spacing between icon and text.

      5.5 has magic number hardcoded in qpushbutton.cpp

          if (!icon().isNull() || showButtonBoxIcons) {
              int ih = opt.iconSize.height();
              int iw = opt.iconSize.width() + 4;
              w += iw;
              h = qMax(h, ih);
          }
      

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

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            aantropov Anton Antropov
            Votes:
            6 Vote for this issue
            Watchers:
            12 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes