Beispiel #1
0
 def __init__(self, parent=None):
     QTableView.__init__(self, parent)
     self.rt_delegate = RichTextDelegate(self)
     self.setSelectionMode(QAbstractItemView.SelectionMode.SingleSelection)
     self.setAlternatingRowColors(True)
     self.setSelectionBehavior(QAbstractItemView.SelectionBehavior.SelectRows)
     self.setIconSize(QSize(24, 24))
     self.clicked.connect(self.show_details)
     self.doubleClicked.connect(self.select_index)
     self.setSortingEnabled(True)
Beispiel #2
0
 def __init__(self, books_view, parent=None):
     QTableView.__init__(self, parent)
     self.books_view = books_view
     self.verticalHeader().close()
     self.splitter = None
     self.disable_save_state = False