개정판 480905f9
issue #506: add instant text copy
Change-Id: I02ff6b9996c511f51bd68d33a6cdc773838449d0
DTI_PID/DTI_PID/MainWindow.py | ||
---|---|---|
1133 | 1133 |
|
1134 | 1134 |
image = self.graphicsView.image().copy(x, y, width, height) |
1135 | 1135 |
dialog = QOcrResultDialog(self.graphicsView, image, QRectF(x, y, width, height)) |
1136 |
modifiers = QApplication.keyboardModifiers() |
|
1137 |
if modifiers == Qt.ControlModifier: |
|
1138 |
return |
|
1136 | 1139 |
(res, textInfoList) = dialog.showDialog() |
1137 | 1140 |
if QDialog.Accepted == res and textInfoList: |
1138 | 1141 |
for textInfo in textInfoList: |
DTI_PID/DTI_PID/OcrResultDialog.py | ||
---|---|---|
209 | 209 |
if self.textInfoList: |
210 | 210 |
self.ui.detectResultTextEdit.setText(self.getPlainText(self.textInfoList)) |
211 | 211 |
self.display_text_rect() |
212 |
|
|
213 |
self.copy_horizontal() |
|
212 | 214 |
else: |
213 | 215 |
self.ui.detectResultTextEdit.setText(self.tr("Not Found")) |
214 | 216 |
except Exception as ex: |
내보내기 Unified diff