- Moved HandleRichText from the folder "chat" to "util" and redesigned the source

- Extended RsHtml::formatText to replace the RetroShare links with an image and enabled this for the certificate links in the system messages (friend recommendation and user request)
- Added new ObjectPainter for painting a button on a pixmap


git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@5160 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
thunder2 2012-05-12 00:40:53 +00:00
parent 5a3863d216
commit dc2d6c975e
27 changed files with 470 additions and 215 deletions

View file

@ -39,6 +39,7 @@
#include "RetroShareLink.h"
#include "channels/ShareKey.h"
#include "notifyqt.h"
#include "util/HandleRichText.h"
#include <retroshare/rspeers.h>
#include <retroshare/rsforums.h>
@ -1165,7 +1166,7 @@ void ForumsDialog::insertPost()
}
}
QString extraTxt = RsHtml::formatText(messageFromInfo(msg), RSHTML_FORMATTEXT_EMBED_SMILEYS | RSHTML_FORMATTEXT_EMBED_LINKS);
QString extraTxt = RsHtml().formatText(ui.postText->document(), messageFromInfo(msg), RSHTML_FORMATTEXT_EMBED_SMILEYS | RSHTML_FORMATTEXT_EMBED_LINKS);
ui.postText->setHtml(extraTxt);
ui.threadTitle->setText(titleFromInfo(msg));