41 |
41 |
42 @signal sourceFile(str, int, str, int, int) emitted to open a source file |
42 @signal sourceFile(str, int, str, int, int) emitted to open a source file |
43 at a specificline |
43 at a specificline |
44 @signal designerFile(str) emitted to open a Qt-Designer file |
44 @signal designerFile(str) emitted to open a Qt-Designer file |
45 """ |
45 """ |
|
46 # TODO: add more signals |
46 sourceFile = pyqtSignal(str, int, str, int, int) |
47 sourceFile = pyqtSignal(str, int, str, int, int) |
47 designerFile = pyqtSignal(str) |
48 designerFile = pyqtSignal(str) |
48 |
49 |
49 lineRole = Qt.ItemDataRole.UserRole + 1 |
50 lineRole = Qt.ItemDataRole.UserRole + 1 |
50 startRole = Qt.ItemDataRole.UserRole + 2 |
51 startRole = Qt.ItemDataRole.UserRole + 2 |
61 @param parent parent widget of this dialog (defaults to None) |
62 @param parent parent widget of this dialog (defaults to None) |
62 @type QWidget (optional) |
63 @type QWidget (optional) |
63 """ |
64 """ |
64 super().__init__(parent) |
65 super().__init__(parent) |
65 self.setupUi(self) |
66 self.setupUi(self) |
66 self.setWindowFlags(Qt.WindowType.Window) |
|
67 |
67 |
68 self.layout().setContentsMargins(0, 3, 0, 0) |
68 self.layout().setContentsMargins(0, 3, 0, 0) |
69 |
69 |
70 self.dirPicker.setMode(EricPathPickerModes.DIRECTORY_MODE) |
70 self.dirPicker.setMode(EricPathPickerModes.DIRECTORY_MODE) |
71 self.dirPicker.setInsertPolicy(QComboBox.InsertPolicy.InsertAtTop) |
71 self.dirPicker.setInsertPolicy(QComboBox.InsertPolicy.InsertAtTop) |
371 @type str |
371 @type str |
372 @return text with eol stripped |
372 @return text with eol stripped |
373 @rtype str |
373 @rtype str |
374 """ |
374 """ |
375 return txt.replace("\r", "").replace("\n", "") |
375 return txt.replace("\r", "").replace("\n", "") |
376 |
376 |
377 @pyqtSlot() |
377 @pyqtSlot() |
378 def __stopSearch(self): |
378 def __stopSearch(self): |
379 """ |
379 """ |
380 Private slot to handle the stop button being pressed. |
380 Private slot to handle the stop button being pressed. |
381 """ |
381 """ |