mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
redo layout on Settings::emojiFontChanged
This commit is contained in:
parent
205f950073
commit
2bc7594049
|
@ -611,6 +611,11 @@ void ChatLog::selectAll()
|
||||||
updateMultiSelectionRect();
|
updateMultiSelectionRect();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ChatLog::forceRelayout()
|
||||||
|
{
|
||||||
|
startResizeWorker();
|
||||||
|
}
|
||||||
|
|
||||||
void ChatLog::checkVisibility()
|
void ChatLog::checkVisibility()
|
||||||
{
|
{
|
||||||
if(lines.empty())
|
if(lines.empty())
|
||||||
|
|
|
@ -49,6 +49,7 @@ public:
|
||||||
void setTypingNotificationVisible(bool visible);
|
void setTypingNotificationVisible(bool visible);
|
||||||
void scrollToLine(ChatLine::Ptr line);
|
void scrollToLine(ChatLine::Ptr line);
|
||||||
void selectAll();
|
void selectAll();
|
||||||
|
void forceRelayout();
|
||||||
|
|
||||||
QString getSelectedText() const;
|
QString getSelectedText() const;
|
||||||
|
|
||||||
|
|
|
@ -53,9 +53,6 @@ void Text::setText(const QString& txt)
|
||||||
|
|
||||||
void Text::setWidth(qreal w)
|
void Text::setWidth(qreal w)
|
||||||
{
|
{
|
||||||
if(w == width)
|
|
||||||
return;
|
|
||||||
|
|
||||||
width = w;
|
width = w;
|
||||||
dirty = true;
|
dirty = true;
|
||||||
|
|
||||||
|
|
|
@ -65,6 +65,8 @@ GenericChatForm::GenericChatForm(QWidget *parent)
|
||||||
chatWidget = new ChatLog(this);
|
chatWidget = new ChatLog(this);
|
||||||
chatWidget->setBusyNotification(ChatMessage::createBusyNotification());
|
chatWidget->setBusyNotification(ChatMessage::createBusyNotification());
|
||||||
|
|
||||||
|
connect(&Settings::getInstance(), &Settings::emojiFontChanged, this, [this]() { chatWidget->forceRelayout(); });
|
||||||
|
|
||||||
msgEdit = new ChatTextEdit();
|
msgEdit = new ChatTextEdit();
|
||||||
|
|
||||||
sendButton = new QPushButton();
|
sendButton = new QPushButton();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user