[Qt-interest] QTableView heading clicked

nora at sappho-net.de nora at sappho-net.de
Mon Sep 20 15:50:45 CEST 2010


Am 20. September 2010 um 15:07:21 +0200 schrieb Marius Roets:

> How do I catch and re-implement the event of the header row being clicked in
> a QTableView. The QTableView clicked() signal is only triggered when
> clicking on data cells.

I've the following:

   // QTableView *tbl;
   // QHeaderView *hhdr;
   ....
   hhdr = tbl->horizontalHeader ();
   ....
   connect (hhdr, SIGNAL (sectionClicked (int)), this, SLOT (hdrClicked (int)));
   ....

Hope, this helps.

Liebe Grüße, Nora.

nora at nxe.de
     IM-NETZ Neue Medien, Berlin                 http://www.im-netz.de/
     WWW von Frauen für Frauen, Hamburg          http://www.w4w.net/
     Lesbian Computer Networks, Helsinki         http://www.sappho.net/




More information about the Qt-interest-old mailing list