code: def add_label_to_table(self, row, col, txt):
          
          label = QLabel(txt)
          label.setMargin(5)
          label.setAlignment(Qt.AlignLeft | Qt.AlignVCenter)
          self.table.setCellWidget(row, col, label)
docs: Add a label to specified cell in table.