From 984d4e4664398ad22dbedaa98bd323624df29525 Mon Sep 17 00:00:00 2001 From: Jonathan White Date: Tue, 24 Dec 2024 08:34:11 -0500 Subject: [PATCH] Fix rendering & and " in password preview --- src/gui/EntryPreviewWidget.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gui/EntryPreviewWidget.cpp b/src/gui/EntryPreviewWidget.cpp index 227e1c934..b6fb90f6c 100644 --- a/src/gui/EntryPreviewWidget.cpp +++ b/src/gui/EntryPreviewWidget.cpp @@ -302,10 +302,12 @@ void EntryPreviewWidget::setPasswordVisible(bool state) html += "" + QString(c).toHtmlEscaped() + ""; } // clang-format on + m_ui->entryPasswordLabel->setTextFormat(Qt::RichText); m_ui->entryPasswordLabel->setText(html); } else { // No color - m_ui->entryPasswordLabel->setText(password.toHtmlEscaped()); + m_ui->entryPasswordLabel->setTextFormat(Qt::PlainText); + m_ui->entryPasswordLabel->setText(password); } } else if (password.isEmpty() && !config()->get(Config::Security_PasswordEmptyPlaceholder).toBool()) { m_ui->entryPasswordLabel->setText("");