[PyQt] How to Generate a "Header Clicked" event for a QTableWidget in PyQt5
Kyle Altendorf
sda at fstab.net
Thu Aug 17 13:56:04 BST 2017
On 2017-08-16 23:45, Eric A wrote:
> I am using PyQt5 and Python 3.5
>
> I see that in PyQt4 there's a "sectionClicked" event for the header in
> a
> QTableWidget in PyQt4, but I don't seem to be able to find that method
> to generate the event signal in PyQt5.
I'm thinking it will be:
your_table_widget.horizontalHeader().sectionClicked.connect(your_callable)
http://doc.qt.io/qt-5/qtableview.html#horizontalHeader
http://doc.qt.io/qt-5/qheaderview.html#sectionClicked
Cheers,
-kyle
More information about the PyQt
mailing list