I want to add new line in the given cursor position in QTextEdit.
I tried what's below.
Here new line is added to the end:
self.textEdit.moveCursor(QTextCursor.PreviousWord)
self.textEdit.moveCursor(QTextCursor.PreviousWord)
self.textEdit.append()
This has no effects at all:
self.textEdit.moveCursor(QTextCursor.PreviousWord)
self.textEdit.moveCursor(QTextCursor.PreviousWord)
self.textEdit.insertHtml('<br>')
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…