]> git.ipfire.org Git - thirdparty/man-pages.git/blob - man5/locale.5
sock_diag.7: ffix: white space tweaks in example program
[thirdparty/man-pages.git] / man5 / locale.5
1 '\" t -*- coding: UTF-8 -*-
2 .\" Copyright (C) 1994 Jochen Hein (Hein@Student.TU-Clausthal.de)
3 .\" Copyright (C) 2008 Petr Baudis (pasky@suse.cz)
4 .\" Copyright (C) 2014 Michael Kerrisk <mtk@manpages@gmail.com>
5 .\"
6 .\" %%%LICENSE_START(GPLv2+_SW_3_PARA)
7 .\" This program is free software; you can redistribute it and/or modify
8 .\" it under the terms of the GNU General Public License as published by
9 .\" the Free Software Foundation; either version 2 of the License, or
10 .\" (at your option) any later version.
11 .\"
12 .\" This program is distributed in the hope that it will be useful,
13 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
14 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 .\" GNU General Public License for more details.
16 .\"
17 .\" You should have received a copy of the GNU General Public
18 .\" License along with this manual; if not, see
19 .\" <http://www.gnu.org/licenses/>.
20 .\" %%%LICENSE_END
21 .\"
22 .\" 2008-06-17 Petr Baudis <pasky@suse.cz>
23 .\" LC_TIME: Describe first_weekday and first_workday
24 .\"
25 .TH LOCALE 5 2016-07-17 "Linux" "Linux User Manual"
26 .SH NAME
27 locale \- describes a locale definition file
28 .SH DESCRIPTION
29 The
30 .B locale
31 definition file contains all the information that the
32 .BR localedef (1)
33 command needs to convert it into the binary locale database.
34
35 The definition files consist of sections which each describe a
36 locale category in detail.
37 See
38 .BR locale (7)
39 for additional details for these categories.
40 .SS Syntax
41 The locale definition file starts with a header that may consist
42 of the following keywords:
43 .TP
44 .I escape_char
45 is followed by a character that should be used as the
46 escape-character for the rest of the file to mark characters that
47 should be interpreted in a special way.
48 It defaults to the backslash (\\).
49 .TP
50 .I comment_char
51 is followed by a character that will be used as the
52 comment-character for the rest of the file.
53 It defaults to the number sign (#).
54 .PP
55 The locale definition has one part for each locale category.
56 Each part can be copied from another existing locale or
57 can be defined from scratch.
58 If the category should be copied,
59 the only valid keyword in the definition is
60 .I copy
61 followed by the name of the locale in double quotes which should be
62 copied.
63 The exceptions for this rule are
64 .B LC_COLLATE
65 and
66 .B LC_CTYPE
67 where a
68 .I copy
69 statement can be followed by locale-specific rules and selected overrides.
70 .PP
71 When defining a category from scratch, all field descriptors and strings
72 should be defined as Unicode code points in angle brackets, unless
73 otherwise stated below.
74 For example, "€" is to be presented as "<U20AC>", "%a" as
75 "<U0025><U0061>", and "Monday" as
76 "<U0053><U0075><U006E><U0064><U0061><U0079>".
77 Values defined as Unicode code points must be in double quotes, plain
78 number values are not quoted (but
79 .BR LC_CTYPE
80 and
81 .BR LC_COLLATE
82 follow special formatting, see the system-provided locale files for
83 examples).
84 .SS Locale category sections
85 The following category sections are defined by POSIX:
86 .IP * 3
87 .B LC_CTYPE
88 .IP *
89 .B LC_COLLATE
90 .IP *
91 .B LC_MESSAGES
92 .IP *
93 .B LC_MONETARY
94 .IP *
95 .B LC_NUMERIC
96 .IP *
97 .B LC_TIME
98 .PP
99 In addition, since version 2.2,
100 the GNU C library supports the following nonstandard categories:
101 .IP * 3
102 .B LC_ADDRESS
103 .IP *
104 .B LC_IDENTIFICATION
105 .IP *
106 .B LC_MEASUREMENT
107 .IP *
108 .B LC_NAME
109 .IP *
110 .B LC_PAPER
111 .IP *
112 .B LC_TELEPHONE
113 .PP
114 See
115 .BR locale (7)
116 for a more detailed description of each category.
117
118 .SS LC_ADDRESS
119 The definition starts with the string
120 .I LC_ADDRESS
121 in the first column.
122
123 The following keywords are allowed:
124 .\" From localedata/locales/uk_UA
125 .TP
126 .I postal_fmt
127 followed by a string containing field descriptors that define
128 the format used for postal addresses in the locale.
129 The following field descriptors are recognized:
130 .RS
131 .TP
132 %n
133 Person's name, possibly constructed with the
134 .B LC_NAME
135 .I name_fmt
136 keyword (since glibc 2.24).
137 .TP 4
138 %a
139 Care of person, or organization.
140 .TP
141 %f
142 Firm name.
143 .TP
144 %d
145 Department name.
146 .TP
147 %b
148 Building name.
149 .TP
150 %s
151 Street or block (e.g., Japanese) name.
152 .TP
153 %h
154 House number or designation.
155 .TP
156 %N
157 Insert an end-of-line if the previous descriptor's value was not an empty
158 string; otherwise ignore.
159 .TP
160 %t
161 Insert a space if the previous descriptor's value was not an empty string;
162 otherwise ignore.
163 .TP
164 %r
165 Room number, door designation.
166 .TP
167 %e
168 Floor number.
169 .TP
170 %C
171 Country designation, from the
172 .I country_post
173 keyword.
174 .TP
175 %l
176 Local township within town or city (since glibc 2.24).
177 .TP
178 %z
179 Zip number, postal code.
180 .TP
181 %T
182 Town, city.
183 .TP
184 %S
185 State, province, or prefecture.
186 .TP
187 %c
188 Country, as taken from data record.
189 .PP
190 Each field descriptor may have an \(aqR\(aq after
191 the \(aq%\(aq to specify that the
192 information is taken from a Romanized version string of the
193 entity.
194 .RE
195 .TP
196 .I country_name
197 followed by the country name in the language of the current document
198 (e.g., "Deutschland" for the
199 .B de_DE
200 locale).
201 .TP
202 .I country_post
203 followed by the abbreviation of the country (see CERT_MAILCODES).
204 .TP
205 .I country_ab2
206 followed by the two-letter abbreviation of the country (ISO 3166).
207 .TP
208 .I country_ab3
209 followed by the three-letter abbreviation of the country (ISO 3166).
210 .TP
211 .I country_num
212 followed by the numeric country code as plain numbers (ISO 3166).
213 .TP
214 .I country_car
215 followed by the international licence plate country code.
216 .TP
217 .I country_isbn
218 followed by the ISBN code (for books).
219 .TP
220 .I lang_name
221 followed by the language name in the language of the current document.
222 .TP
223 .I lang_ab
224 followed by the two-letter abbreviation of the language (ISO 639).
225 .TP
226 .I lang_term
227 followed by the three-letter abbreviation of the language (ISO 639-2/T).
228 .TP
229 .I lang_lib
230 followed by the three-letter abbreviation of the language for library
231 use (ISO 639-2/B).
232 Applications should in general prefer
233 .IR lang_term
234 over
235 .IR lang_lib .
236 .PP
237 The
238 .B LC_ADDRESS
239 definition ends with the string
240 .IR "END LC_ADDRESS" .
241 .SS LC_CTYPE
242 The definition starts with the string
243 .I LC_CTYPE
244 in the first column.
245
246 The following keywords are allowed:
247 .TP
248 .I upper
249 followed by a list of uppercase letters.
250 The letters
251 .B A
252 through
253 .B Z
254 are included automatically.
255 Characters also specified as
256 .BR cntrl ,
257 .BR digit ,
258 .BR punct ,
259 or
260 .B space
261 are not allowed.
262 .TP
263 .I lower
264 followed by a list of lowercase letters.
265 The letters
266 .B a
267 through
268 .B z
269 are included automatically.
270 Characters also specified as
271 .BR cntrl ,
272 .BR digit ,
273 .BR punct ,
274 or
275 .B space
276 are not allowed.
277 .TP
278 .I alpha
279 followed by a list of letters.
280 All character specified as either
281 .B upper
282 or
283 .B lower
284 are automatically included.
285 Characters also specified as
286 .BR cntrl ,
287 .BR digit ,
288 .BR punct ,
289 or
290 .B space
291 are not allowed.
292 .TP
293 .I digit
294 followed by the characters classified as numeric digits.
295 Only the
296 digits
297 .B 0
298 through
299 .B 9
300 are allowed.
301 They are included by default in this class.
302 .TP
303 .I space
304 followed by a list of characters defined as white-space
305 characters.
306 Characters also specified as
307 .BR upper ,
308 .BR lower ,
309 .BR alpha ,
310 .BR digit ,
311 .BR graph ,
312 or
313 .B xdigit
314 are not allowed.
315 The characters
316 .BR <space> ,
317 .BR <form-feed> ,
318 .BR <newline> ,
319 .BR <carriage-return> ,
320 .BR <tab> ,
321 and
322 .B <vertical-tab>
323 are automatically included.
324 .TP
325 .I cntrl
326 followed by a list of control characters.
327 Characters also specified as
328 .BR upper ,
329 .BR lower ,
330 .BR alpha ,
331 .BR digit ,
332 .BR punct ,
333 .BR graph ,
334 .BR print ,
335 or
336 .B xdigit
337 are not allowed.
338 .TP
339 .I punct
340 followed by a list of punctuation characters.
341 Characters also
342 specified as
343 .BR upper ,
344 .BR lower ,
345 .BR alpha ,
346 .BR digit ,
347 .BR cntrl ,
348 .BR xdigit ,
349 or the
350 .B <space>
351 character are not allowed.
352 .TP
353 .I graph
354 followed by a list of printable characters, not including the
355 .B <space>
356 character.
357 The characters defined as
358 .BR upper ,
359 .BR lower ,
360 .BR alpha ,
361 .BR digit ,
362 .BR xdigit ,
363 and
364 .B punct
365 are automatically included.
366 Characters also specified as
367 .B cntrl
368 are not allowed.
369 .TP
370 .I print
371 followed by a list of printable characters, including the
372 .B <space>
373 character.
374 The characters defined as
375 .BR upper ,
376 .BR lower ,
377 .BR alpha ,
378 .BR digit ,
379 .BR xdigit ,
380 .BR punct ,
381 and the
382 .B <space>
383 character are automatically included.
384 Characters also specified as
385 .B cntrl
386 are not allowed.
387 .TP
388 .I xdigit
389 followed by a list of characters classified as hexadecimal
390 digits.
391 The decimal digits must be included followed by one or
392 more set of six characters in ascending order.
393 The following
394 characters are included by default:
395 .B 0
396 through
397 .BR 9 ,
398 .B a
399 through
400 .BR f ,
401 .B A
402 through
403 .BR F .
404 .TP
405 .I blank
406 followed by a list of characters classified as
407 .BR blank .
408 The characters
409 .B <space>
410 and
411 .B <tab>
412 are automatically included.
413 .TP
414 .I charclass
415 followed by a list of locale-specific character class names
416 which are then to be defined in the locale.
417 .TP
418 .I toupper
419 followed by a list of mappings from lowercase to uppercase
420 letters.
421 Each mapping is a pair of a lowercase and an uppercase letter
422 separated with a
423 .B ,
424 and enclosed in parentheses.
425 The members of the list are separated
426 with semicolons.
427 .TP
428 .I tolower
429 followed by a list of mappings from uppercase to lowercase
430 letters.
431 If the keyword tolower is not present, the reverse of the
432 toupper list is used.
433 .TP
434 .I map totitle
435 followed by a list of mapping pairs of
436 characters and letters
437 to be used in titles (headings).
438 .TP
439 .I class
440 followed by a locale-specific character class definition,
441 starting with the class name followed by the characters
442 belonging to the class.
443 .TP
444 .I charconv
445 followed by a list of locale-specific character mapping names
446 which are then to be defined in the locale.
447 .TP
448 .I outdigit
449 followed by a list of alternate output digits for the locale.
450 .TP
451 .I map to_inpunct
452 followed by a list of mapping pairs of
453 alternate digits and separators
454 for input digits for the locale.
455 .TP
456 .I map to_outpunct
457 followed by a list of mapping pairs of
458 alternate separators
459 for output for the locale.
460 .TP
461 .I translit_start
462 marks the start of the transliteration rules section.
463 The section can contain the
464 .I include
465 keyword in the beginning followed by
466 locale-specific rules and overrides.
467 Any rule specified in the locale file
468 will override any rule
469 copied or included from other files.
470 In case of duplicate rule definitions in the locale file,
471 only the first rule is used.
472
473 A transliteration rule consist of a character to be transliterated
474 followed by a list of transliteration targets separated by semicolons.
475 The first target which can be presented in the target character set
476 is used, if none of them can be used the
477 .I default_missing
478 character will be used instead.
479 .TP
480 .I include
481 in the transliteration rules section includes
482 a transliteration rule file
483 (and optionally a repertoire map file).
484 .TP
485 .I default_missing
486 in the transliteration rules section
487 defines the default character to be used for
488 transliteration where none of the targets cannot be presented
489 in the target character set.
490 .TP
491 .I translit_end
492 marks the end of the transliteration rules.
493 .PP
494 The
495 .B LC_CTYPE
496 definition ends with the string
497 .IR "END LC_CTYPE" .
498 .SS LC_COLLATE
499 Note that glibc does not support all POSIX-defined options,
500 only the options described below are supported (as of glibc 2.23).
501
502 The definition starts with the string
503 .I LC_COLLATE
504 in the first column.
505
506 The following keywords are allowed:
507 .TP
508 .I coll_weight_max
509 followed by the number representing used collation levels.
510 This keyword is recognized but ignored by glibc.
511 .TP
512 .I collating-element
513 followed by the definition of a collating-element symbol
514 representing a multicharacter collating element.
515 .TP
516 .I collating-symbol
517 followed by the definition of a collating symbol
518 that can be used in collation order statements.
519 .TP
520 .I define
521 followed by
522 .B string
523 to be evaluated in an
524 .I ifdef
525 .B string
526 /
527 .I else
528 /
529 .I endif
530 construct.
531 .TP
532 .I reorder-after
533 followed by a redefinition of a collation rule.
534 .TP
535 .I reorder-end
536 marks the end of the redefinition of a collation rule.
537 .TP
538 .I reorder-sections-after
539 followed by a script name to reorder listed scripts after.
540 .TP
541 .I reorder-sections-end
542 marks the end of the reordering of sections.
543 .TP
544 .I script
545 followed by a declaration of a script.
546 .TP
547 .I symbol-equivalence
548 followed by a collating-symbol to be equivalent to another defined
549 collating-symbol.
550 .PP
551 The collation rule definition starts with a line:
552 .TP
553 .I order_start
554 followed by a list of keywords chosen from
555 .BR forward ,
556 .BR backward ,
557 or
558 .BR position .
559 The order definition consists of lines that describe the collation
560 order and is terminated with the keyword
561 .IR order_end .
562 .PP
563 The
564 .B LC_COLLATE
565 definition ends with the string
566 .IR "END LC_COLLATE" .
567 .SS LC_IDENTIFICATION
568 The definition starts with the string
569 .I LC_IDENTIFICATION
570 in the first column.
571
572 The values in this category are defined as plain strings.
573
574 The following keywords are allowed:
575 .TP
576 .I title
577 followed by the title of the locale document
578 (e.g., "Maori language locale for New Zealand").
579 .TP
580 .I source
581 followed by the name of the organization that maintains this document.
582 .TP
583 .I address
584 followed by the address of the organization that maintains this document.
585 .TP
586 .I contact
587 followed by the name of the contact person at
588 the organization that maintains this document.
589 .TP
590 .I email
591 followed by the email address of the person or
592 organization that maintains this document.
593 .TP
594 .I tel
595 followed by the telephone number (in international format)
596 of the organization that maintains this document.
597 As of glibc 2.24, this keyword is deprecated in favor of
598 other contact methods.
599 .TP
600 .I fax
601 followed by the fax number (in international format)
602 of the organization that maintains this document.
603 As of glibc 2.24, this keyword is deprecated in favor of
604 other contact methods.
605 .TP
606 .I language
607 followed by the name of the language to which this document applies.
608 .TP
609 .I territory
610 followed by the name of the country/geographic extent
611 to which this document applies.
612 .TP
613 .I audience
614 followed by a description of the audience for which this document is
615 intended.
616 .TP
617 .I application
618 followed by a description of any special application
619 for which this document is intended.
620 .TP
621 .I abbreviation
622 followed by the short name for provider of the source of this document.
623 .TP
624 .I revision
625 followed by the revision number of this document.
626 .TP
627 .I date
628 followed by the revision date of this document.
629 .PP
630 In addition, for each of the categories defined by the document,
631 there should be a line starting with the keyword
632 .IR category ,
633 followed by:
634 .IP * 3
635 a string that identifies this locale category definition,
636 .IP *
637 a semicolon, and
638 .IP *
639 one of the
640 .BI LC_ *
641 identifiers.
642 .PP
643 The
644 .B LC_IDENTIFICATION
645 definition ends with the string
646 .IR "END LC_IDENTIFICATION" .
647 .SS LC_MESSAGES
648 The definition starts with the string
649 .I LC_MESSAGES
650 in the first column.
651
652 The following keywords are allowed:
653 .TP
654 .I yesexpr
655 followed by a regular expression that describes possible
656 yes-responses.
657 .TP
658 .I noexpr
659 followed by a regular expression that describes possible
660 no-responses.
661 .TP
662 .I yesstr
663 followed by the output string corresponding to "yes".
664 .TP
665 .I nostr
666 followed by the output string corresponding to "no".
667 .PP
668 The
669 .B LC_MESSAGES
670 definition ends with the string
671 .IR "END LC_MESSAGES" .
672 .SS LC_MEASUREMENT
673 The definition starts with the string
674 .I LC_MEASUREMENT
675 in the first column.
676
677 The following keywords are allowed:
678 .TP
679 .I measurement
680 followed by number identifying the standard used for measurement.
681 The following values are recognized:
682 .RS
683 .TP 4
684 .B 1
685 Metric.
686 .TP
687 .B 2
688 US customary measurements.
689 .RE
690 .PP
691 The
692 .B LC_MEASUREMENT
693 definition ends with the string
694 .IR "END LC_MEASUREMENT" .
695 .SS LC_MONETARY
696 The definition starts with the string
697 .I LC_MONETARY
698 in the first column.
699
700 Values for
701 .IR int_curr_symbol ,
702 .IR currency_symbol ,
703 .IR mon_decimal_point ,
704 .IR mon_thousands_sep ,
705 .IR positive_sign ,
706 and
707 .IR negative_sign
708 are defined as Unicode code points, the others as plain numbers.
709
710 The following keywords are allowed:
711 .TP
712 .I int_curr_symbol
713 followed by the international currency symbol.
714 This must be a
715 4-character string containing the international currency symbol as
716 defined by the ISO 4217 standard (three characters) followed by a
717 separator.
718 .TP
719 .I currency_symbol
720 followed by the local currency symbol.
721 .TP
722 .I mon_decimal_point
723 followed by the string that will be used as the decimal delimiter
724 when formatting monetary quantities.
725 .TP
726 .I mon_thousands_sep
727 followed by the string that will be used as a group separator
728 when formatting monetary quantities.
729 .TP
730 .I mon_grouping
731 followed by a sequence of integers separated by semicolons that
732 describe the formatting of monetary quantities.
733 See
734 .I grouping
735 below for details.
736 .TP
737 .I positive_sign
738 followed by a string that is used to indicate a positive sign for
739 monetary quantities.
740 .TP
741 .I negative_sign
742 followed by a string that is used to indicate a negative sign for
743 monetary quantities.
744 .TP
745 .I int_frac_digits
746 followed by the number of fractional digits that should be used when
747 formatting with the
748 .IR int_curr_symbol .
749 .TP
750 .I frac_digits
751 followed by the number of fractional digits that should be used when
752 formatting with the
753 .IR currency_symbol .
754 .TP
755 .I p_cs_precedes
756 followed by an integer that indicates the placement of
757 .I currency_symbol
758 for a nonnegative formatted monetary quantity:
759 .RS
760 .TP 4
761 .B 0
762 the symbol succeeds the value.
763 .TP
764 .B 1
765 the symbol precedes the value.
766 .RE
767 .TP
768 .I p_sep_by_space
769 followed by an integer that indicates the separation of
770 .IR currency_symbol ,
771 the sign string, and the value for a nonnegative formatted monetary quantity.
772 The following values are recognized:
773 .RS
774 .TP 4
775 .B 0
776 No space separates the currency symbol and the value.
777 .TP
778 .B 1
779 If the currency symbol and the sign string are adjacent,
780 a space separates them from the value;
781 otherwise a space separates the currency symbol and the value.
782 .TP
783 .B 2
784 If the currency symbol and the sign string are adjacent,
785 a space separates them from the value;
786 otherwise a space separates the sign string and the value.
787 .RE
788 .TP
789 .I n_cs_precedes
790 followed by an integer that indicates the placement of
791 .I currency_symbol
792 for a negative formatted monetary quantity.
793 The same values are recognized as for
794 .IR p_cs_precedes .
795 .TP
796 .I n_sep_by_space
797 followed by an integer that indicates the separation of
798 .IR currency_symbol ,
799 the sign string, and the value for a negative formatted monetary quantity.
800 The same values are recognized as for
801 .IR p_sep_by_space .
802 .TP
803 .I p_sign_posn
804 followed by an integer that indicates where the
805 .I positive_sign
806 should be placed for a nonnegative monetary quantity:
807 .RS
808 .TP 4
809 .B 0
810 Parentheses enclose the quantity and the
811 .I currency_symbol
812 or
813 .IR int_curr_symbol .
814 .TP
815 .B 1
816 The sign string precedes the quantity and the
817 .I currency_symbol
818 or the
819 .IR int_curr_symbol .
820 .TP
821 .B 2
822 The sign string succeeds the quantity and the
823 .I currency_symbol
824 or the
825 .IR int_curr_symbol .
826 .TP
827 .B 3
828 The sign string precedes the
829 .I currency_symbol
830 or the
831 .IR int_curr_symbol .
832 .TP
833 .B 4
834 The sign string succeeds the
835 .I currency_symbol
836 or the
837 .IR int_curr_symbol .
838 .RE
839 .TP
840 .I n_sign_posn
841 followed by an integer that indicates where the
842 .I negative_sign
843 should be placed for a negative monetary quantity.
844 The same values are recognized as for
845 .IR p_sign_posn .
846 .TP
847 .I int_p_cs_precedes
848 followed by an integer that indicates the placement of
849 .I int_curr_symbol
850 for a nonnegative internationally formatted monetary quantity.
851 The same values are recognized as for
852 .IR p_cs_precedes .
853 .TP
854 .I int_n_cs_precedes
855 followed by an integer that indicates the placement of
856 .I int_curr_symbol
857 for a negative internationally formatted monetary quantity.
858 The same values are recognized as for
859 .IR p_cs_precedes .
860 .TP
861 .I int_p_sep_by_space
862 followed by an integer that indicates the separation of
863 .IR int_curr_symbol ,
864 the sign string,
865 and the value for a nonnegative internationally formatted monetary quantity.
866 The same values are recognized as for
867 .IR p_sep_by_space .
868 .TP
869 .I int_n_sep_by_space
870 followed by an integer that indicates the separation of
871 .IR int_curr_symbol ,
872 the sign string,
873 and the value for a negative internationally formatted monetary quantity.
874 The same values are recognized as for
875 .IR p_sep_by_space .
876 .TP
877 .I int_p_sign_posn
878 followed by an integer that indicates where the
879 .I positive_sign
880 should be placed for a nonnegative
881 internationally formatted monetary quantity.
882 The same values are recognized as for
883 .IR p_sign_posn .
884 .TP
885 .I int_n_sign_posn
886 followed by an integer that indicates where the
887 .I negative_sign
888 should be placed for a negative
889 internationally formatted monetary quantity.
890 The same values are recognized as for
891 .IR p_sign_posn .
892 .PP
893 The
894 .B LC_MONETARY
895 definition ends with the string
896 .IR "END LC_MONETARY" .
897 .SS LC_NAME
898 The definition starts with the string
899 .I LC_NAME
900 in the first column.
901
902 Various keywords are allowed, but only
903 .IR name_fmt
904 is mandatory.
905 Other keywords are needed only if there is common convention to
906 use the corresponding salutation in this locale.
907 The allowed keywords are as follows:
908 .TP
909 .I name_fmt
910 followed by a string containing field descriptors that define
911 the format used for names in the locale.
912 The following field descriptors are recognized:
913 .\" From localedata/locales/uk_UA
914 .RS
915 .TP 4
916 %f
917 Family name(s).
918 .TP
919 %F
920 Family names in uppercase.
921 .TP
922 %g
923 First given name.
924 .TP
925 %G
926 First given initial.
927 .TP
928 %l
929 First given name with Latin letters.
930 .TP
931 %o
932 Other shorter name.
933 .TP
934 %m
935 Additional given name(s).
936 .TP
937 %M
938 Initials for additional given name(s).
939 .TP
940 %p
941 Profession.
942 .TP
943 %s
944 Salutation, such as "Doctor".
945 .TP
946 %S
947 Abbreviated salutation, such as "Mr." or "Dr.".
948 .TP
949 %d
950 Salutation, using the FDCC-sets conventions.
951 .\" 1 for the name_gen
952 .\" In glibc 2.19, %d1 is used in only:
953 .\" /home/mtk/ARCHIVE/GLIBC/glibc-2.19/localedata/locales/bem_ZM
954 .\" /home/mtk/ARCHIVE/GLIBC/glibc-2.19/localedata/locales/zh_HK
955 .\" In glibc 2.19, %d[2-5] appear to be not used at all
956 .\" 2 for name_mr
957 .\" 3 for name_mrs
958 .\" 4 for name_miss
959 .\" 5 for name_ms
960 .TP
961 %t
962 If the preceding field descriptor resulted in an empty string,
963 then the empty string, otherwise a space character.
964 .RE
965 .TP
966 .I name_gen
967 followed by the general salutation for any gender.
968 .TP
969 .I name_mr
970 followed by the salutation for men.
971 .TP
972 .I name_mrs
973 followed by the salutation for married women.
974 .TP
975 .I name_miss
976 followed by the salutation for unmarried women.
977 .TP
978 .I name_ms
979 followed by the salutation valid for all women.
980 .PP
981 The
982 .B LC_NAME
983 definition ends with the string
984 .IR "END LC_NAME" .
985 .SS LC_NUMERIC
986 The definition starts with the string
987 .I LC_NUMERIC
988 in the first column.
989
990 The following keywords are allowed:
991 .TP
992 .I decimal_point
993 followed by the string that will be used as the decimal delimiter
994 when formatting numeric quantities.
995 .TP
996 .I thousands_sep
997 followed by the string that will be used as a group separator
998 when formatting numeric quantities.
999 .TP
1000 .I grouping
1001 followed by a sequence of integers as plain numbers separated by
1002 semicolons that describe the formatting of numeric quantities.
1003 .IP
1004 Each integer specifies the number of digits in a group.
1005 The first integer defines the size of the group immediately
1006 to the left of the decimal delimiter.
1007 Subsequent integers define succeeding groups to the
1008 left of the previous group.
1009 If the last integer is not \-1, then the size of the previous group
1010 (if any) is repeatedly used for the remainder of the digits.
1011 If the last integer is \-1, then no further grouping is performed.
1012 .PP
1013 The
1014 .B LC_NUMERIC
1015 definition ends with the string
1016 .IR "END LC_NUMERIC" .
1017 .SS LC_PAPER
1018 The definition starts with the string
1019 .I LC_PAPER
1020 in the first column.
1021
1022 Values in this category are defined as plain numbers.
1023
1024 The following keywords are allowed:
1025 .TP
1026 .I height
1027 followed by the height, in millimeters, of the standard paper format.
1028 .TP
1029 .I width
1030 followed by the width, in millimeters, of the standard paper format.
1031 .PP
1032 The
1033 .B LC_PAPER
1034 definition ends with the string
1035 .IR "END LC_PAPER" .
1036 .SS LC_TELEPHONE
1037 The definition starts with the string
1038 .I LC_TELEPHONE
1039 in the first column.
1040
1041 The following keywords are allowed:
1042 .TP
1043 .I tel_int_fmt
1044 followed by a string that contains field descriptors that identify
1045 the format used to dial international numbers.
1046 The following field descriptors are recognized:
1047 .\" From localedata/locales/uk_UA
1048 .RS
1049 .TP 4
1050 %a
1051 Area code without nationwide prefix (the prefix is often "00").
1052 .TP
1053 %A
1054 Area code including nationwide prefix.
1055 .TP
1056 %l
1057 Local number (within area code).
1058 .TP
1059 %e
1060 Extension (to local number).
1061 .TP
1062 %c
1063 Country code.
1064 .TP
1065 %C
1066 Alternate carrier service code used for dialing abroad.
1067 .TP
1068 %t
1069 If the preceding field descriptor resulted in an empty string,
1070 then the empty string, otherwise a space character.
1071 .RE
1072 .TP
1073 .I tel_dom_fmt
1074 followed by a string that contains field descriptors that identify
1075 the format used to dial domestic numbers.
1076 The recognized field descriptors are the same as for
1077 .IR tel_int_fmt .
1078 .TP
1079 .I int_select
1080 followed by the prefix used to call international phone numbers.
1081 .TP
1082 .I int_prefix
1083 followed by the prefix used from other countries to dial this country.
1084 .PP
1085 The
1086 .B LC_TELEPHONE
1087 definition ends with the string
1088 .IR "END LC_TELEPHONE" .
1089 .SS LC_TIME
1090 The definition starts with the string
1091 .I LC_TIME
1092 in the first column.
1093
1094 The following keywords are allowed:
1095 .TP
1096 .I abday
1097 followed by a list of abbreviated names of the days of the week.
1098 The list starts with the first day of the week
1099 as specified by
1100 .I week
1101 (Sunday by default).
1102 See NOTES.
1103 .TP
1104 .I day
1105 followed by a list of names of the days of the week.
1106 The list starts with the first day of the week
1107 as specified by
1108 .I week
1109 (Sunday by default).
1110 See NOTES.
1111 .TP
1112 .I abmon
1113 followed by a list of abbreviated month names.
1114 .TP
1115 .I mon
1116 followed by a list of month names.
1117 .TP
1118 .I d_t_fmt
1119 followed by the appropriate date and time format
1120 (for syntax, see
1121 .BR strftime (3)).
1122 .TP
1123 .I d_fmt
1124 followed by the appropriate date format
1125 (for syntax, see
1126 .BR strftime (3)).
1127 .TP
1128 .I t_fmt
1129 followed by the appropriate time format
1130 (for syntax, see
1131 .BR strftime (3)).
1132 .TP
1133 .I am_pm
1134 followed by the appropriate representation of the
1135 .B am
1136 and
1137 .B pm
1138 strings.
1139 This should be left empty for locales not using AM/PM convention.
1140 .TP
1141 .I t_fmt_ampm
1142 followed by the appropriate time format
1143 (for syntax, see
1144 .BR strftime (3))
1145 when using 12h clock format.
1146 This should be left empty for locales not using AM/PM convention.
1147 .TP
1148 .I era
1149 followed by semicolon-separated strings that define how years are
1150 counted and displayed for each era in the locale.
1151 Each string has the following format:
1152 .RS
1153 .PP
1154 .IR direction ":" offset ":" start_date ":" end_date ":" era_name ":" era_format
1155 .PP
1156 The fields are to be defined as follows:
1157 .PP
1158 .TP 4
1159 .I direction
1160 Either
1161 .BR +
1162 or
1163 .BR -.
1164 .BR +
1165 means the years closer to
1166 .IR start_date
1167 have lower numbers than years closer to
1168 .IR end_date .
1169 .BR -
1170 means the opposite.
1171 .TP
1172 .I offset
1173 The number of the year closest to
1174 .IR start_date
1175 in the era, corresponding to the
1176 .IR %Ey
1177 descriptor (see
1178 .BR strptime (3)).
1179 .TP
1180 .I start_date
1181 The start of the era in the form of
1182 .IR yyyy/mm/dd .
1183 Years prior AD 1 are represented as negative numbers.
1184 .TP
1185 .I end_date
1186 The end of the era in the form of
1187 .IR yyyy/mm/dd ,
1188 or one of the two special values of
1189 .BR -*
1190 or
1191 .BR +* .
1192 .BR -*
1193 means the ending date is the beginning of time.
1194 .BR +*
1195 means the ending date is the end of time.
1196 .TP
1197 .I era_name
1198 The name of the era corresponding to the
1199 .I %EC
1200 descriptor (see
1201 .BR strptime (3)).
1202 .TP
1203 .I era_format
1204 The format of the year in the era corresponding to the
1205 .I %EY
1206 descriptor (see
1207 .BR strptime (3)).
1208 .RE
1209 .TP
1210 .I era_d_fmt
1211 followed by the format of the date in alternative era notation,
1212 corresponding to the
1213 .I %Ex
1214 descriptor (see
1215 .BR strptime (3)).
1216 .TP
1217 .I era_t_fmt
1218 followed by the format of the time in alternative era notation,
1219 corresponding to the
1220 .I %EX
1221 descriptor (see
1222 .BR strptime (3)).
1223 .TP
1224 .I era_d_t_fmt
1225 followed by the format of the date and time in alternative era notation,
1226 corresponding to the
1227 .I %Ec
1228 descriptor (see
1229 .BR strptime (3)).
1230 .TP
1231 .I alt_digits
1232 followed by the alternative digits used for date and time in the locale.
1233 .TP
1234 .I week
1235 followed by a list of three values as plain numbers:
1236 The number of days in a week (by default 7),
1237 a date of beginning of the week (by default corresponds to Sunday),
1238 and the minimal length of the first week in year (by default 4).
1239 Regarding the start of the week,
1240 .B 19971130
1241 shall be used for Sunday and
1242 .B 19971201
1243 shall be used for Monday.
1244 See NOTES.
1245 .TP
1246 .IR first_weekday " (since glibc 2.2)"
1247 followed by the number of the first day from the
1248 .I day
1249 list to be shown in calendar applications.
1250 The default value of
1251 .B 1
1252 (plain number) corresponds to either Sunday or Monday depending
1253 on the value of the second
1254 .I week
1255 list item.
1256 See NOTES.
1257 .TP
1258 .IR first_workday " (since glibc 2.2)"
1259 followed by the number of the first working day from the
1260 .I day
1261 list.
1262 The default value is
1263 .BR 2
1264 (plain number).
1265 See NOTES.
1266 .TP
1267 .I cal_direction
1268 .\" From localedata/locales/uk_UA
1269 followed by a plain number value that indicates the direction for the
1270 display of calendar dates, as follows:
1271 .RS
1272 .TP 4
1273 .B 1
1274 Left-right from top.
1275 .TP
1276 .B 2
1277 Top-down from left.
1278 .TP
1279 .B 3
1280 Right-left from top.
1281 .RE
1282 .TP
1283 .I date_fmt
1284 followed by the appropriate date representation for
1285 .BR date (1)
1286 (for syntax, see
1287 .BR strftime (3)).
1288 .PP
1289 The
1290 .B LC_TIME
1291 definition ends with the string
1292 .IR "END LC_TIME" .
1293 .SH FILES
1294 .TP
1295 .I /usr/lib/locale/locale-archive
1296 Usual default locale archive location.
1297 .TP
1298 .I /usr/share/i18n/locales
1299 Usual default path for locale definition files.
1300 .SH CONFORMING TO
1301 POSIX.2.
1302 .SH NOTES
1303 The collective GNU C library community wisdom regarding
1304 .IR abday ,
1305 .IR day ,
1306 .IR week ,
1307 .IR first_weekday ,
1308 and
1309 .I first_workday
1310 states at
1311 https://sourceware.org/glibc/wiki/Locales
1312 the following:
1313 .IP * 3
1314 The value of the second
1315 .I week
1316 list item specifies the base of the
1317 .I abday
1318 and
1319 .I day
1320 lists.
1321 .IP *
1322 .I first_weekday
1323 specifies the offset of the first day-of-week in the
1324 .I abday
1325 and
1326 .I day
1327 lists.
1328 .IP *
1329 For compatibility reasons, all glibc locales should set the value of the
1330 second
1331 .I week
1332 list item to
1333 .B 19971130
1334 (Sunday) and base the
1335 .I abday
1336 and
1337 .I day
1338 lists appropriately, and set
1339 .I first_weekday
1340 and
1341 .I first_workday
1342 to
1343 .B 1
1344 or
1345 .BR 2 ,
1346 depending on whether the week and work week actually starts on Sunday or
1347 Monday for the locale.
1348 .\" .SH AUTHOR
1349 .\" Jochen Hein (Hein@Student.TU-Clausthal.de)
1350 .SH SEE ALSO
1351 .BR iconv (1),
1352 .BR locale (1),
1353 .BR localedef (1),
1354 .BR localeconv (3),
1355 .BR newlocale (3),
1356 .BR setlocale (3),
1357 .BR strftime (3),
1358 .BR strptime (3),
1359 .BR uselocale (3),
1360 .BR charmap (5),
1361 .BR charsets (7),
1362 .BR locale (7),
1363 .BR unicode (7),
1364 .BR utf-8 (7)