Kleopatra could allow more customization by taking a custom logo and a custom window title from config. This is useful for GnuPG VS-Desktop customization.
Description
Description
Revisions and Commits
Revisions and Commits
rLIBKLEO Libkleo | |||
rLIBKLEO39bbfda2b029 Add API to read branding icon and title | |||
rKLEOPATRA Kleopatra | |||
rKLEOPATRA8c4142481acc Add branding icon and window title if set |
Event Timeline
Comment Actions
To add an icon:
diff --git a/src/kleopatra.rc b/src/kleopatra.rc index 2284dfb8..936789e5 100644 --- a/src/kleopatra.rc +++ b/src/kleopatra.rc @@ -1,5 +1,5 @@ <!DOCTYPE gui > -<gui name="kleopatra" version="509" > +<gui name="kleopatra" version="512" > <MenuBar> <Menu name="file"> <text>&File</text> @@ -112,6 +112,11 @@ <Action name="view_certificate_overview"/> <Action name="pad_view"/> <Action name="manage_smartcard"/> + <Separator/> + </ToolBar> + <ToolBar iconSize="64" fullWidth="false" name="subtoolbar" iconText="TextBesideIcon"> + <Separator/> + <Action name="help_about_custom"/> </ToolBar> <Menu name="listview_popup"> diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 343ff328..cd7e05a9 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -499,6 +499,10 @@ void MainWindow::Private::setupActions() "gpg4win-compact", q, [this](bool) { forceUpdateCheck(); }, QString() }, #endif + { + "help_about_custom", i18n("GnuPG\nVS-Desktop"), QString(), + "firewall-applet-shields_up", q, SLOT(aboutApplication()), QString(), false, true + }, // View menu { "view_certificate_overview", i18nc("@action show certificate overview", "Certificates"),
Comment Actions
Using SLOT doesn't work anymore. The "slot" needs to be a std::function<void(bool)> (e.g. a lambda) now. Moreover, the trailing false, true is not required anymore (because of suitable enum value defaults for those action_data members).