mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
fixes issue #2868
This commit is contained in:
parent
e5e4d561c9
commit
54fabb964c
|
@ -138,7 +138,7 @@ ChatForm::~ChatForm()
|
|||
void ChatForm::setStatusMessage(QString newMessage)
|
||||
{
|
||||
statusMessageLabel->setText(newMessage);
|
||||
statusMessageLabel->setToolTip(newMessage.toHtmlEscaped()); // for overlength messsages
|
||||
statusMessageLabel->setToolTip(Qt::convertFromPlainText(newMessage, Qt::WhiteSpaceNormal)); // for overlength messsages
|
||||
}
|
||||
|
||||
void ChatForm::onSendTriggered()
|
||||
|
|
|
@ -272,7 +272,7 @@ QDate GenericChatForm::getLatestDate() const
|
|||
void GenericChatForm::setName(const QString &newName)
|
||||
{
|
||||
nameLabel->setText(newName);
|
||||
nameLabel->setToolTip(newName.toHtmlEscaped()); // for overlength names
|
||||
nameLabel->setToolTip(Qt::convertFromPlainText(newName, Qt::WhiteSpaceNormal)); // for overlength names
|
||||
}
|
||||
|
||||
void GenericChatForm::show(ContentLayout* contentLayout)
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
#include <QResizeEvent>
|
||||
#include <QLineEdit>
|
||||
#include <QKeyEvent>
|
||||
#include <QTextDocument>
|
||||
|
||||
CroppingLabel::CroppingLabel(QWidget* parent)
|
||||
: QLabel(parent)
|
||||
|
@ -126,7 +127,7 @@ void CroppingLabel::setElidedText()
|
|||
{
|
||||
QString elidedText = fontMetrics().elidedText(origText, elideMode, width());
|
||||
if (elidedText != origText)
|
||||
setToolTip(origText.toHtmlEscaped());
|
||||
setToolTip(Qt::convertFromPlainText(origText, Qt::WhiteSpaceNormal));
|
||||
else
|
||||
setToolTip(QString());
|
||||
|
||||
|
|
|
@ -838,7 +838,7 @@ void Widget::setUsername(const QString& username)
|
|||
else
|
||||
{
|
||||
ui->nameLabel->setText(username);
|
||||
ui->nameLabel->setToolTip(username.toHtmlEscaped()); // for overlength names
|
||||
ui->nameLabel->setToolTip(Qt::convertFromPlainText(username, Qt::WhiteSpaceNormal)); // for overlength names
|
||||
}
|
||||
|
||||
QString sanename = username;
|
||||
|
@ -863,7 +863,7 @@ void Widget::setStatusMessage(const QString &statusMessage)
|
|||
else
|
||||
{
|
||||
ui->statusLabel->setText(statusMessage);
|
||||
ui->statusLabel->setToolTip(statusMessage.toHtmlEscaped()); // for overlength messsages
|
||||
ui->statusLabel->setToolTip(Qt::convertFromPlainText(statusMessage, Qt::WhiteSpaceNormal)); // for overlength messsages
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user