Add table header.

This commit is contained in:
Andrey Golovizin 2014-08-25 12:31:33 +02:00
parent 8a875d90bd
commit 79a1a95a43

View file

@ -56,6 +56,12 @@ class GlyphDBModel(QAbstractTableModel):
self.images[key] = image
return image
def headerData(self, section, orientation, role):
if orientation != Qt.Horizontal or role != Qt.DisplayRole:
return None
if section == 0:
return 'Text'
def data(self, index, role):
if index.column() == 0:
key = self.keys[index.row()]