pyuic5 bug with QFontComboBox

Baz Walter bazwal at
Wed Oct 6 20:52:15 BST 2021

When using PyQt-5.15.4, the ui compiler cannot handle QFontDatabase enums.

The minimal test-case below raises the following exception:

     PyQt5.uic.exceptions.NoSuchClassError: Unknown C++ class: QFontDatabase


     from io import StringIO
     from PyQt5 import uic, QtWidgets

     app = QtWidgets.QApplication(['test'])

     <?xml version="1.0" encoding="UTF-8"?>
     <ui version="4.0">
      <widget class="QWidget" name="Form">
       <widget class="QFontComboBox" name="fontComboBox">
        <property name="writingSystem">

(NB: ui file was generated by Qt Designer 5.15.2)
-------------- next part --------------
A non-text attachment was scrubbed...
Type: text/x-python
Size: 450 bytes
Desc: not available
URL: <>

More information about the PyQt mailing list