>From 44ec61406bcf64cc2ac25d59724f10e15f3f9aa4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miguel=20=C3=81ngel=20Arruga=20Vivas?= Date: Mon, 6 May 2019 16:19:26 +0200 Subject: [PATCH 10/15] doc: Update po_message_t API (III) * gettext-tools/doc/gettext.texi (po_message_t API): Add po_message_set_msgctxt, po_message_set_msgid, po_message_set_msgid_plural, po_message_set_msgstr, po_message_set_msgstr_plural, po_message_set_comments, and po_message_set_extracted_comments documentation. --- gettext-tools/doc/gettext.texi | 55 +++++++++++++++++++++++++++++++++- 1 file changed, 54 insertions(+), 1 deletion(-) diff --git a/gettext-tools/doc/gettext.texi b/gettext-tools/doc/gettext.texi index 251293e37..28d050613 100644 --- a/gettext-tools/doc/gettext.texi +++ b/gettext-tools/doc/gettext.texi @@ -5481,7 +5481,7 @@ into a file to manage its memory, as there is no @code{po_message_free} available to the user of the library. @end deftypefun -The following functions returns details of a @code{po_message_t}. Recall +The following functions access details of a @code{po_message_t}. Recall that the results are valid as long as the @var{file} handle is valid. @deftypefun {const char *} po_message_msgctxt (po_message_t @var{message}) @@ -5490,39 +5490,92 @@ context of the message. Return @code{NULL} for a message not restricted to a context. @end deftypefun address@hidden {void} po_message_set_msgctxt (po_message_t @var{message},@ + const char address@hidden) +The @code{po_message_set_msgctxt} function changes the @code{msgctxt}, +the context of the message, to the value provided through address@hidden The value @code{NULL} removes the restriction. address@hidden deftypefun + @deftypefun {const char *} po_message_msgid (po_message_t @var{message}) The @code{po_message_msgid} function returns the @code{msgid} (untranslated English string) of a message. This is guaranteed to be address@hidden @end deftypefun address@hidden {void} po_message_set_msgid (po_message_t @var{message},@ + const char address@hidden) +The @code{po_message_set_msgid} function changes the @code{msgid} +(untranslated English string) of a message to the value provided through address@hidden, a address@hidden string. address@hidden deftypefun + @deftypefun {const char *} po_message_msgid_plural (po_message_t @var{message}) The @code{po_message_msgid_plural} function returns the @code{msgid_plural} (untranslated English plural string) of a message with plurals, or @code{NULL} for a message without plural. @end deftypefun address@hidden {void} po_message_set_msgid_plural (po_message_t @var{message},@ + const char address@hidden) +The @code{po_message_set_msgid_plural} function changes the address@hidden (untranslated English plural string) of a message to +the value provided through @var{msgid_plural}, or removes the plurals if address@hidden is provided as @var{msgid_plural}. address@hidden deftypefun + @deftypefun {const char *} po_message_msgstr (po_message_t @var{message}) The @code{po_message_msgstr} function returns the @code{msgstr} (translation) of a message. For an untranslated message, the return value is an empty string. @end deftypefun address@hidden {void} po_message_set_msgstr (po_message_t @var{message},@ + const char address@hidden) +The @code{po_message_set_msgstr} function changes the @code{msgstr} +(translation) of a message to the value provided through @var{msgstr}, a address@hidden string. address@hidden deftypefun + @deftypefun {const char *} po_message_msgstr_plural (po_message_t @var{message}, int @var{index}) The @code{po_message_msgstr_plural} function returns the @address@hidden of a message with plurals, or @code{NULL} when the @var{index} is out of range or for a message without plural. @end deftypefun address@hidden {void} po_message_set_msgstr_plural (po_message_t @var{message},@ + int @var{index}, const char address@hidden) +The @code{po_message_set_msgstr_plural} function changes the address@hidden@var{index}]} of a message with plurals to the value +provided through @var{msgstr_plural}. @var{message} must be a message +with plurals. Use @code{NULL} as the value of @var{msgstr_plural} with address@hidden pointing to the last element to reduce the number of plural +forms. address@hidden deftypefun + @deftypefun {const char *} po_message_comments (po_message_t @var{message}) The @code{po_message_comments} function returns the comments of a message, a multiline string, ending in a newline, or a address@hidden empty string. @end deftypefun address@hidden {void} po_message_set_comments (po_message_t @var{message},@ + const char address@hidden) +The @code{po_message_set_comments} function changes the comments of a +message to the value @var{comments}, a multiline string, ending in a +newline, or a address@hidden empty string. address@hidden deftypefun + @deftypefun {const char *} po_message_extracted_comments (po_message_t @var{message}) The @code{po_message_extracted_comments} function returns the extracted comments of a message, a multiline string, ending in a newline, or a address@hidden empty string. @end deftypefun address@hidden {void} po_message_set_extracted_comments (po_message_t @var{message},@ + const char address@hidden) +The @code{po_message_set_extracted_comments} function changes the +comments of a message to the value @var{extracted_comments}, a multiline +string, ending in a newline, or a address@hidden empty string. address@hidden deftypefun + @node Binaries @chapter Producing Binary MO Files -- 2.21.0