diff --git a/man5/locale.5 b/man5/locale.5 index e6c1f075a..22cda04ba 100644 --- a/man5/locale.5 +++ b/man5/locale.5 @@ -1067,11 +1067,6 @@ The definition starts with the string in the first column. The following keywords are allowed: -.\" FIXME The following LC_TIME keywords are not documented: -.\" era -.\" era_d_fmt -.\" era_d_t_fmt -.\" era_t_fmt .TP .I abday followed by a list of abbreviated names of the days of the week. @@ -1125,6 +1120,89 @@ followed by the appropriate time format when using 12h clock format. This should be left empty for locales not using AM/PM convention. .TP +.I era +followed by semicolon-separated strings that define how years are +counted and displayed for each era in the locale. +Each string has the following format: +.RS +.PP +.IR direction ":" offset ":" start_date ":" end_date ":" era_name ":" era_format +.PP +The fields are to be defined as follows: +.PP +.TP 4 +.I direction +Either +.BR + +or +.BR -. +.BR + +means the years closer to +.IR start_date +have lower numbers than years closer to +.IR end_date . +.BR - +means the opposite. +.TP +.I offset +The number of the year closest to +.IR start_date +in the era, corresponding to the +.IR %Ey +descriptor (see +.BR strptime (3)). +.TP +.I start_date +The start of the era in the form of +.IR yyyy/mm/dd . +Years prior AD 1 are represented as negative numbers. +.TP +.I end_date +The end of the era in the form of +.IR yyyy/mm/dd , +or one of the two special values of +.BR -* +or +.BR +* . +.BR -* +means the ending date is the beginning of time. +.BR +* +means the ending date is the end of time. +.TP +.I era_name +The name of the era corresponding to the +.I %EC +descriptor (see +.BR strptime (3)). +.TP +.I era_format +The format of the year in the era corresponding to the +.I %EY +descriptor (see +.BR strptime (3)). +.RE +.TP +.I era_d_fmt +followed by the format of the date in alternative era notation, +corresponding to the +.I %Ex +descriptor (see +.BR strptime (3)). +.TP +.I era_t_fmt +followed by the format of the time in alternative era notation, +corresponding to the +.I %EX +descriptor (see +.BR strptime (3)). +.TP +.I era_d_t_fmt +followed by the format of the date and time in alternative era notation, +corresponding to the +.I %Ec +descriptor (see +.BR strptime (3)). +.TP .I alt_digits followed by the alternative digits used for date and time in the locale. .TP @@ -1254,6 +1332,7 @@ This manual page isn't complete. .BR newlocale (3), .BR setlocale (3), .BR strftime (3), +.BR strptime (3), .BR uselocale (3), .BR charmap (5), .BR charsets (7),