#6 .desktop file validation

open
nobody
None
5
2012-09-23
2009-05-19
Pino Toscano
No

The kdiff3.desktop file, used for showing KDiff3 in XDG menus (like KDE's, GNOME's, XFCE's) is not totally compliant, as executing desktop-file-validate on it shows. Furthermore, specifies no categories, so it could be not shown at all (or in some "lost+found" category).

The attached patch fixes the following problems:
- removes the deprecated %m marker from the Exec key
- renames the non-standard KDE-specific DocPath key to X-DocPath, as changed with KDE 4
- adds a list of two categories, "Qt" (as it for sure a Qt application) and "Development" (being a mostly-development tool)

References:
- http://standards.freedesktop.org/desktop-entry-spec/latest/http://standards.freedesktop.org/menu-spec/latest/apa.html
- http://standards.freedesktop.org/menu-spec/latest/apa.html

Discussion

  • Pino Toscano
    Pino Toscano
    2009-05-19

    .desktop fix

     
    Attachments
  • I'd love to see this patch in trunk too. I looks terribly when there is "Lost and Found" in menu where only one application is.

     
  • Ori Avtalion
    Ori Avtalion
    2009-10-06

    According to freedesktop's specification ( http://standards.freedesktop.org/menu-spec/menu-spec-1.0.html ):

    The "Qt" category is used for apps based on Qt libs, but since kdiff3 can optionally use KDE libs (and does in most distros), maybe "KDE" is a better category.

    These .desktop files are also invalidated. The "UTF-8" key needs to be removed:
    kdiff3plugin-QT4/kdiff3_plugin.desktop
    kdiff3plugin-QT4/kdiff3plugin.desktop

    (I'd attach the patch, but sf.net doesn't allow that)

     

  • Anonymous
    2012-02-15

    Why no add both, KDE and Qt to the categories?

    Categories=Qt;KDE;Development;