mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-12-25 23:39:45 -05:00
Fix rendering & and " in password preview
This commit is contained in:
parent
af0c1644a6
commit
984d4e4664
@ -302,10 +302,12 @@ void EntryPreviewWidget::setPasswordVisible(bool state)
|
|||||||
html += "<span style=\"color: " + QString(color) + ";\">" + QString(c).toHtmlEscaped() + "</span>";
|
html += "<span style=\"color: " + QString(color) + ";\">" + QString(c).toHtmlEscaped() + "</span>";
|
||||||
}
|
}
|
||||||
// clang-format on
|
// clang-format on
|
||||||
|
m_ui->entryPasswordLabel->setTextFormat(Qt::RichText);
|
||||||
m_ui->entryPasswordLabel->setText(html);
|
m_ui->entryPasswordLabel->setText(html);
|
||||||
} else {
|
} else {
|
||||||
// No color
|
// 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()) {
|
} else if (password.isEmpty() && !config()->get(Config::Security_PasswordEmptyPlaceholder).toBool()) {
|
||||||
m_ui->entryPasswordLabel->setText("");
|
m_ui->entryPasswordLabel->setText("");
|
||||||
|
Loading…
Reference in New Issue
Block a user