user3551782
user3551782

Reputation: 153

PyQt4 QTextBrowser set text at the end

Dear stackoverflow community;

I've got a QTextBrowser widget, I set a text on it via QTDesigner, now I need to set another line of text to it via code. My code:

self.ui.textStatus.append('text')

I don't find a working append method for a QTextBrowser object, any idea how to do so?

Kind regards;

Upvotes: 0

Views: 11600

Answers (1)

Nerkyator
Nerkyator

Reputation: 3976

self.ui.textStatus.setText(self.ui.textStatus.text() + ' text')

Anyway, from what I can read in the documentation QTextBrowser inherits from QTextEdit and it has the append() method (just tried in a dummy app)..

Upvotes: 8

Related Questions