mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-05-09 10:05:23 -04:00
Replace application icons with Material Design icons.
Use the following to run KeePassXC with the icons from the source code, ignoring the operating system's Qt icon theme: ``` KEEPASSXC_IGNORE_ICON_THEME=1 keepassxc ``` The patch further adds a script `makeicons.sh` that re-creates KeePassXC icons from the Material Design icon set and can be used for easily updating icons in the future. Instructions are in the script. Fixes #475
This commit is contained in:
parent
470838f21c
commit
36f92b7649
238 changed files with 306 additions and 9562 deletions
|
@ -30,16 +30,19 @@ LineEdit::LineEdit(QWidget* parent)
|
|||
{
|
||||
m_clearButton->setObjectName("clearButton");
|
||||
|
||||
QIcon icon;
|
||||
QString iconNameDirected =
|
||||
QString("edit-clear-locationbar-").append((layoutDirection() == Qt::LeftToRight) ? "rtl" : "ltr");
|
||||
icon = QIcon::fromTheme(iconNameDirected);
|
||||
if (icon.isNull()) {
|
||||
icon = QIcon::fromTheme("edit-clear");
|
||||
|
||||
QIcon icon;
|
||||
if (!getenv("KEEPASSXC_IGNORE_ICON_THEME")) {
|
||||
icon = QIcon::fromTheme(iconNameDirected);
|
||||
if (icon.isNull()) {
|
||||
icon = filePath()->icon("actions", iconNameDirected);
|
||||
icon = QIcon::fromTheme("edit-clear");
|
||||
}
|
||||
}
|
||||
if (icon.isNull()) {
|
||||
icon = filePath()->icon("actions", iconNameDirected);
|
||||
}
|
||||
|
||||
m_clearButton->setIcon(icon);
|
||||
m_clearButton->setCursor(Qt::ArrowCursor);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue