This is a minor problem but it irritates me
I use PyQt
I use Qt Designer
I use PyUic5 to generate the Ui_MyDialog from the output of the Qt designer
I created a custom widget and a plugin and managed to operate an insertion
of my custom widget to a dialog
I managed to operate the dialog and see my custom widget in action.
The problem is that in the Ui_MyDialog.py that is generated by the PyUic5 there
is (at the end of the file) an import for my custom widget and the file name of my custom widget is in lowercase letters and not the way the file is
I looked in the plugin and there is no place where such a filename is declared
What can be the problem?
I gave here the whole file. The problem is in the last line
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'Ui\PlotDialog.ui'
#
# Created by: PyQt5 UI code generator 5.6
#
# WARNING! All changes made in this file will be lost!
from PyQt5 import QtCore, QtGui, QtWidgets
class Ui_PlotDialog(object):
def setupUi(self, PlotDialog):
PlotDialog.setObjectName("PlotDialog")
PlotDialog.resize(400, 300)
self.horizontalLayout = QtWidgets.QHBoxLayout(PlotDialog)
self.horizontalLayout.setObjectName("horizontalLayout")
self.myQtPlotContainer = MyQtPlotConteiner(PlotDialog)
self.myQtPlotContainer.setObjectName("myQtPlotContainer")
self.horizontalLayout.addWidget(self.myQtPlotContainer)
self.buttonBox = QtWidgets.QDialogButtonBox(PlotDialog)
self.buttonBox.setOrientation(QtCore.Qt.Vertical)
self.buttonBox.setStandardButtons (QtWidgets.QDialogButtonBox.Cancel|QtWidgets.QDialogButtonBox.Ok)
self.buttonBox.setObjectName("buttonBox")
self.horizontalLayout.addWidget(self.buttonBox)
self.retranslateUi(PlotDialog)
self.buttonBox.accepted.connect(PlotDialog.accept)
self.buttonBox.rejected.connect(PlotDialog.reject)
QtCore.QMetaObject.connectSlotsByName(PlotDialog)
def retranslateUi(self, PlotDialog):
_translate = QtCore.QCoreApplication.translate
PlotDialog.setWindowTitle(_translate("PlotDialog", "Dialog"))
self.myQtPlotContainer.setToolTip(_translate("PlotDialog", "The current time"))
self.myQtPlotContainer.setWhatsThis(_translate("PlotDialog", "The analog clock widget displays the current time."))
from myqtplotconteiner import MyQtPlotConteiner