How to get Index Row number from Source Model
问题 Clicking the QTableView " Item_B_001 " prints out its row number # 0 . But in source model's self.items this item corresponds to the number # 3. How to get a "real" Source Model's Item's row number - a number it really corresponds to? from PyQt4.QtCore import * from PyQt4.QtGui import * import sys class Model(QAbstractTableModel): def __init__(self, parent=None, *args): QAbstractTableModel.__init__(self, parent, *args) self.items = ['Item_A_001','Item_A_002','Item_B_001','Item_B_002'] def