I have an object of type QTableWidget in which I need to add a certain number of times to the new row, to the first column the row number, and to the second new object of the type QTextEditor. But the number will be set by the user. And in the future it will be necessary to read the value of each of the QTextEditor. I tried to implement it by brute force, but the object does not appear in the table. Here is a piece of code:
for _ in range(self.output_text.count(replacement_symbol)): input_replacement = QTextEdit(self.table_of_replacements) input_replacement.resize(195, 25) self.list_of_replacement.append(input_replacement) self.table_of_replacements.setCellWidget(_, 0, input_replacement) 