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

QComboBox font settings does not work when Fusion style is used

    XMLWordPrintable

Details

    • 6ecc1e800649ce037008af4afd09a9c5d8648418

    Description

      When Fusion style is used font settings are not working with QComboBox.

      #include "mainwindow.h"
      #include <QApplication>
      #include <QComboBox>
      #include <QProxyStyle>
      #include <QPainter>
      
      int main(int argc, char *argv[])
      {
          QApplication a(argc, argv);
          QComboBox box;
          box.addItems(QStringList() << "one" << "two" << "three");
          QFont font;
          font.setBold(true);
          font.setItalic(true);
          font.setPixelSize(20);
          box.setItemData(0, font, Qt::FontRole);
          box.show();
      
          return a.exec();
      }
      
      

      Attachments

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

        Activity

          People

            mitch_curtis Mitch Curtis
            anylitok Antti Yli-Tokola (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes