mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-27 00:19:25 -05:00
fixing margins & hide notes field when its empty
This commit is contained in:
parent
b96fecfcbb
commit
f482e681e3
@ -21,6 +21,7 @@
|
||||
#include <QDateTime>
|
||||
#include <QMenu>
|
||||
#include <QStyle>
|
||||
#include <QTextDocument>
|
||||
|
||||
#include "rshare.h"
|
||||
#include "PostedCardView.h"
|
||||
@ -332,7 +333,10 @@ void PostedCardView::fill()
|
||||
// FIX THIS UP LATER.
|
||||
ui->notes->setText(RsHtml().formatText(NULL, QString::fromUtf8(mPost.mNotes.c_str()), RSHTML_FORMATTEXT_EMBED_SMILEYS | RSHTML_FORMATTEXT_EMBED_LINKS));
|
||||
|
||||
if(ui->notes->text().isEmpty())
|
||||
QTextDocument doc;
|
||||
doc.setHtml(ui->notes->text());
|
||||
|
||||
if(doc.toPlainText().trimmed().isEmpty())
|
||||
ui->notes->hide();
|
||||
// differences between Feed or Top of Comment.
|
||||
if (mFeedHolder)
|
||||
|
@ -465,6 +465,15 @@
|
||||
<property name="leftMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLabel" name="pictureLabel">
|
||||
<property name="text">
|
||||
|
Loading…
Reference in New Issue
Block a user