Does QTableWidget have an event that occurs when you move up / down the table with the keys? Something I can not find.
1 answer
Regardless of how you move the arrows or the mouse, the itemSelectionChanged signal is itemSelectionChanged .
from PyQt5 import Qt def on_selection(): print("Selection changed") if __name__ == "__main__": app = Qt.QApplication([]) widget = Qt.QTableWidget() widget.setRowCount(10) widget.setColumnCount(10) widget.itemSelectionChanged.connect(on_selection) widget.show() app.exec() - Thank you very much, it works. - MyNick 2:51 pm
|