{
    "content": [
        {
            "type": "text",
            "text": "# Dpkg::Gettext (info)\n\n## NAME\n\nDpkg::Gettext - convenience wrapper around Locale::gettext\n\n## DESCRIPTION\n\nThe Dpkg::Gettext module is a convenience wrapper over the\nLocale::gettext module, to guarantee we always have working gettext\nfunctions, and to add some commonly used aliases.\n\n## Sections\n\n- **NAME**\n- **DESCRIPTION**\n- **ENVIRONMENT**\n- **VARIABLES**\n- **FUNCTIONS**\n- **CHANGES**\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "Dpkg::Gettext",
        "section": "",
        "mode": "info",
        "summary": "Dpkg::Gettext - convenience wrapper around Locale::gettext",
        "synopsis": null,
        "tldr_summary": null,
        "tldr_examples": [],
        "tldr_source": null,
        "flags": [],
        "examples": [],
        "see_also": [],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 4,
                "subsections": []
            },
            {
                "name": "ENVIRONMENT",
                "lines": 4,
                "subsections": []
            },
            {
                "name": "VARIABLES",
                "lines": 9,
                "subsections": []
            },
            {
                "name": "FUNCTIONS",
                "lines": 34,
                "subsections": []
            },
            {
                "name": "CHANGES",
                "lines": 21,
                "subsections": []
            }
        ],
        "sections": {
            "NAME": {
                "content": "Dpkg::Gettext - convenience wrapper around Locale::gettext\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "The Dpkg::Gettext module is a convenience wrapper over the\nLocale::gettext module, to guarantee we always have working gettext\nfunctions, and to add some commonly used aliases.\n",
                "subsections": []
            },
            "ENVIRONMENT": {
                "content": "DPKGNLS\nWhen set to 0, this environment variable will disable the National\nLanguage Support in all Dpkg modules.\n",
                "subsections": []
            },
            "VARIABLES": {
                "content": "$Dpkg::Gettext::DEFAULTTEXTDOMAIN\nSpecifies the default text domain name to be used with the short\nfunction aliases. This is intended to be used by the Dpkg modules,\nso that they can produce localized messages even when the calling\nprogram has set the current domain with textdomain(). If you would\nlike to use the aliases for your own modules, you might want to set\nthis variable to undef, or to another domain, but then the Dpkg\nmodules will not produce localized messages.\n",
                "subsections": []
            },
            "FUNCTIONS": {
                "content": "$domain = textdomain($newdomain)\nCompatibility textdomain() fallback when Locale::gettext is not\navailable.\n\nIf $newdomain is not undef, it will set the current domain to\n$newdomain.  Returns the current domain, after possibly changing\nit.\n\n$trans = ngettext($msgid, $msgidplural, $n)\nCompatibility ngettext() fallback when Locale::gettext is not\navailable.\n\nReturns $msgid if $n is 1 or $msgidplural otherwise.\n\n$trans = g($msgid)\nCalls dgettext() on the $msgid and returns its translation for the\ncurrent locale. If dgettext() is not available, simply returns\n$msgid.\n\n$trans = C($msgctxt, $msgid)\nCalls dgettext() on the $msgid and returns its translation for the\nspecific $msgctxt supplied. If dgettext() is not available, simply\nreturns $msgid.\n\n$trans = P($msgid, $msgidplural, $n)\nCalls dngettext(), returning the correct translation for the plural\nform dependent on $n. If dngettext() is not available, returns\n$msgid if $n is 1 or $msgidplural otherwise.\n\n$msgid = N($msgid)\nA pseudo function that servers as a marked for automated extraction\nof messages, but does not call gettext(). The run-time translation\nis done at a different place in the code.\n",
                "subsections": []
            },
            "CHANGES": {
                "content": "Version 2.00 (dpkg 1.20.0)\nRemove function: g().\n\nVersion 1.03 (dpkg 1.19.0)\nNew envvar: Add support for new DPKGNLS environment variable.\n\nVersion 1.02 (dpkg 1.18.3)\nNew function: N().\n\nVersion 1.01 (dpkg 1.18.0)\nNow the short aliases (g and P) will call domain aware functions with\n$DEFAULTTEXTDOMAIN.\n\nNew functions: g(), C().\n\nDeprecated function: g().\n\nVersion 1.00 (dpkg 1.15.6)\nMark the module as public.\n\n1.21.1                            2025-09-09              Dpkg::Gettext(3perl)",
                "subsections": []
            }
        }
    }
}