Skip to content

Commit

Permalink
Close #552: issues with icons in gnome dock
Browse files Browse the repository at this point in the history
coreApp->setOrganizationDomain() expects the domain
in DNS order (hohnstaedt.de) and not reversed.

Change the WM_CLASS property to "de.hohnstaedt.xca"
via setApplicationName().
While Qt6 prepends the reversed "OrganizationDomain",
Qt5 does not and setting the complete name with
domain-prefix works for both.

Also adopt the ".desktop" file name to follow the application-name
and fix issues found by "desktop-file-validate"
  • Loading branch information
chris2511 committed Sep 7, 2024
1 parent d315010 commit 775939b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
4 changes: 2 additions & 2 deletions lib/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,8 @@ int main(int argc, char *argv[])
UI_method_set_writer(uimeth.data(), uiwriter);
UI_set_default_method(uimeth.data());

coreApp->setApplicationName(PACKAGE_TARNAME);
coreApp->setOrganizationDomain("de.hohnstaedt");
coreApp->setApplicationName("de.hohnstaedt.xca");
coreApp->setOrganizationDomain("hohnstaedt.de");
coreApp->setApplicationVersion(XCA_VERSION);
xcaWarning::setGui(new xcaWarningCore());

Expand Down
2 changes: 1 addition & 1 deletion misc/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ if (UNIX AND NOT APPLE)
install(FILES ${TEXT_FILES} ${XCA_TEMPLATES}
DESTINATION ${CMAKE_INSTALL_DATADIR}/${CMAKE_PROJECT_NAME}
)
install(FILES misc/xca.desktop
install(FILES misc/de.hohnstaedt.xca.desktop
DESTINATION ${CMAKE_INSTALL_DATADIR}/applications
)
install(FILES misc/xca.completion
Expand Down
3 changes: 1 addition & 2 deletions misc/xca.desktop → misc/de.hohnstaedt.xca.desktop
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
[Desktop Entry]
Encoding=UTF-8
Name=XCA
Type=Application
Comment=A graphical user interface for handling and issuing X.509 compliant Certificates
Expand All @@ -15,5 +14,5 @@ Comment[it]=Interfaccia grafica per generare e gestire certificati X.509
Exec=xca %F
Icon=de.hohnstaedt.xca
Terminal=false
Categories=Application;Utility;Qt;
Categories=Utility;Qt
MimeType=application/x-xca-database;application/x-xca-template;application/x-x509-ca-cert;application/pkcs10;application/x-pkcs7-certificates;application/x-pkcs12;

0 comments on commit 775939b

Please sign in to comment.