]> Savannah Git Hosting - gnulib.git/commitdiff
propername-lite: Improve documentation.
authorBruno Haible <bruno@clisp.org>
Sat, 3 Jun 2023 10:31:21 +0000 (12:31 +0200)
committerBruno Haible <bruno@clisp.org>
Sat, 3 Jun 2023 10:31:21 +0000 (12:31 +0200)
* lib/propername.h: Describe functional differences between
proper_name_lite and proper_name_utf8.

ChangeLog
lib/propername.h

index 56eac7fe9b4b773d958af29b620f8c2472bb2c20..fa13d3860b05e20755601b7b1f8e368870ccd1ad 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2023-06-03  Bruno Haible  <bruno@clisp.org>
+
+       propername-lite: Improve documentation.
+       * lib/propername.h: Describe functional differences between
+       proper_name_lite and proper_name_utf8.
+
 2023-06-03  Bruno Haible  <bruno@clisp.org>
 
        gnulib-tool: Keep in sync with last change to gnulib-tool.py.
index eced2e86da4baf3f1e3fd96cd051eae5414e8c3a..7bd57b24a4395facc789878ca1537ae65d8570b2 100644 (file)
@@ -45,7 +45,7 @@
      ...
      Written by Danilo Segan and Bruno Haible.
 
-   The 'propername' and 'propername-lite modules do this. Plus, for
+   The 'propername' and 'propername-lite' modules do this. Plus, for
    languages that do not use the Latin alphabet, they allow a translator
    to write the name using that different writing system. In that case the
    propername and propername_utf8 output will look like this:
@@ -75,7 +75,7 @@
         proper_name_utf8 should use octal escapes, not UTF-8 - e.g.,
         "Fran\303\247ois Pinard", not "François Pinard".  Doing it
         this way can avoid mishandling non-ASCII characters if the
-        source is recoded to non-UTF8, or if the compiler does not
+        source is recoded to non-UTF-8, or if the compiler does not
         treat UTF-8 as-is in character string contents.
 
         (Optionally, here you can also add / * TRANSLATORS: ... * / comments
                     In the original Cyrillic it is "Данило Шеган".  * /
                 proper_name_utf8 ("Danilo Segan", "Danilo \305\240egan"),
                 proper_name ("Bruno Haible"));
+
+   Differences between proper_name_utf8 and proper_name_lite:
+   * proper_name_lite uses the localization provided by the translator.
+     If there is no localization, it uses the name with Unicode characters
+     only in UTF-8 locales, otherwise it uses the original name in English.
+   * proper_name_utf8 is more elaborate:
+     - It uses the name with Unicode characters also when the locale encoding
+       is not UTF-8 but contains the necessary characters (e.g. ISO-8859-x or
+       GB18030).
+     - If there is a localization, it produces a better result when the
+       translator has given a poor localization.
  */
 
 #ifndef _PROPERNAME_H