Uploaded image for project: 'Qbs ("Cubes")'
  1. Qbs ("Cubes")
  2. QBS-1805

freedesktop Module Fails to Support Localized Versions of Desktop Entry Records

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Not Evaluated
    • None
    • 1.16.0, 2.5
    • API: JavaScript
    • None
    • Linux/Wayland, Linux/X11, Linux/Other display system
    • 3dcd36891 (master)

    Description

      According to the Desktop Entry Specification:

      Keys with type localestring and iconstring may be postfixed by [LOCALE], where LOCALE is the locale type of the entry. The LOCALE must be of the form lang_COUNTRY.ENCODING@MODIFIER, where _COUNTRY, .ENCODING, and @MODIFIER may be omitted. If a postfixed key occurs, the same key must also be present without the postfix.

      However, in the current implementation of the freedesktop module, localized versions of records are not supported. The presence of such records causes the original desktop entry file to break.

      Steps to Reproduce:

      1. Create a desktop entry file with localized versions of keys using the [LOCALE] postfix.
      2. Attempt to parse the file using the freedesktop module.
      3. Observe that the presence of localized keys breaks the file, causing it to be unusable.

      Expected Behavior: The freedesktop module should correctly handle localized versions of records according to the Desktop Entry Specification, selecting the appropriate key based on the current LC_MESSAGES value and ensuring that the file remains functional.

      Actual Behavior: Localized versions of records are not supported, and their presence breaks the original desktop entry file.

      Additional Context: This issue affects projects relying on the freedesktop module for handling desktop entry files in localized environments. Proper support for localized keys is essential for maintaining compatibility with the Desktop Entry Specification.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            kandeler Christian Kandeler
            dismine Roman Telezhynskyi
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes