+void ChatWidget::insertStyledText(const QtopiaUiStyle::StyledText &stext) {
+ QTextCursor cursor = textCursor();
+ foreach(QTextLayout::FormatRange format, stext.formatList) {
+ cursor.setCharFormat(format.format);
+ setTextCursor(cursor);
+ insertPlainText(stext.plainText.mid(format.start, format.length));
+ }