diff -r f4775ae8f441 -r 74a3b2a6a944 eric7/E5Gui/E5ComboBox.py --- a/eric7/E5Gui/E5ComboBox.py Fri May 21 18:01:11 2021 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,66 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyright (c) 2012 - 2021 Detlev Offenbach <detlev@die-offenbachs.de> -# - -""" -Module implementing combobox classes using the eric line edits. -""" - -from PyQt6.QtWidgets import QComboBox - - -class E5ComboBox(QComboBox): - """ - Class implementing a combobox using the eric line edit. - """ - def __init__(self, parent=None, inactiveText=""): - """ - Constructor - - @param parent reference to the parent widget (QWidget) - @param inactiveText text to be shown on inactivity (string) - """ - super().__init__(parent) - - self.setMinimumHeight(24) - - from .E5LineEdit import E5LineEdit - self.__lineedit = E5LineEdit(self, inactiveText) - self.setLineEdit(self.__lineedit) - - self.setMinimumHeight(self.__lineedit.minimumHeight() + 3) - - def inactiveText(self): - """ - Public method to get the inactive text. - - @return inactive text (string) - """ - return self.lineEdit().inactiveText() - - def setInactiveText(self, inactiveText): - """ - Public method to set the inactive text. - - @param inactiveText text to be shown on inactivity (string) - """ - self.lineEdit().setInactiveText(inactiveText) - - -class E5ClearableComboBox(E5ComboBox): - """ - Class implementing a combobox using the eric line edit. - """ - def __init__(self, parent=None, inactiveText=""): - """ - Constructor - - @param parent reference to the parent widget (QWidget) - @param inactiveText text to be shown on inactivity (string) - """ - super().__init__(parent, inactiveText) - - from .E5LineEdit import E5ClearableLineEdit - self.__lineedit = E5ClearableLineEdit(self, inactiveText) - self.setLineEdit(self.__lineedit)