struct lconv;
member | type | value in "C" locale | description |
---|---|---|---|
decimal_point | char* | "." | Decimal-point separator used for non-monetary quantities. |
thousands_sep | char* | "" | Separators used to delimit groups of digits to the left of the decimal point for non-monetary quantities. |
grouping | char* | "" | Specifies the amount of digits that form each of the groups to be separated by thousands_sep separator for non-monetary quantities. This is a zero-terminated sequence of char values that may contain different grouping sizes for each successive group starting from the right, each number indicating the amount of digits for the group; the last number before the ending zero in this string is used for the remaining groups. For example, assuming thousand_sep is set to "," and the number to represent is one million (1000000 ):with grouping set to "\3" , the number would be represented as: 1,000,000 with grouping set to "\1\2\3" , the number would be represented as: 1,000,00,0 with grouping set to "\3\1" , the number would be represented as: 1,0,0,0,000 CHAR_MAX indicates that no further grouping is to be performed. |
int_curr_symbol | char* | "" | International currency symbol. This is formed by the three-letter ISO-4217 entry code for the currency, like "USD" for U.S.-Dollar or "GBP" for Pound Sterling, followed by the character used to separate this symbol from the monetary quantity |
currency_symbol | char* | "" | Local currency symbol, like "$" . |
mon_decimal_point | char* | "" | Decimal-point separator used for monetary quantities. |
mon_thousands_sep | char* | "" | Separators used to delimit groups of digits to the left of the decimal point for monetary quantities. |
mon_grouping | char* | "" | Specifies the amount of digits that form each of the groups to be separated by mon_thousands_sep separator for monetary quantities. See grouping description above. |
positive_sign | char* | "" | Sign to be used for nonnegative (positive or zero) monetary quantities. |
negative_sign | char* | "" | Sign to be used for negative monetary quantities. |
frac_digits | char | CHAR_MAX | Amount of fractional digits to the right of the decimal point for monetary quantities in the local format. |
p_cs_precedes | char | CHAR_MAX | Whether the currency symbol should precede nonnegative (positive or zero) monetary quantities. If this value is 1 , the currency symbol should precede; if it is 0 , it should follow. |
n_cs_precedes | char | CHAR_MAX | Whether the currency symbol should precede negative monetary quantities. If this value is 1 , the currency symbol should precede; if it is 0 it should follow. |
p_sep_by_space | char | CHAR_MAX | Whether a space should appear between the currency symbol and nonnegative (positive or zero) monetary quantities. If this value is 1 , a space should appear; if it is 0 it should not. |
n_sep_by_space | char | CHAR_MAX | Whether a space should appear between the currency symbol and negative monetary quantities. If this value is 1 , a space should appear; if it is 0 it should not. |
p_sign_posn | char | CHAR_MAX | Position of the sign for nonnegative (positive or zero) monetary quantities: 0 : Currency symbol and quantity surrounded by parentheses. 1 : Sign before the quantity and currency symbol. 2 : Sign after the quantity and currency symbol. 3 : Sign right before currency symbol. 4 : Sign right after currency symbol. CHAR_MAX : Unspecified. |
n_sign_posn | char | CHAR_MAX | Position of the sign for negative monetary quantities. See p_sign_posn above. |
int_frac_digits | char | CHAR_MAX | Same as frac_digits, but for the international format (instead of the local format). |
int_p_cs_precedes | char | CHAR_MAX | Same as p_cs_precedes, but for the international format. |
int_n_cs_precedes | char | CHAR_MAX | Same as n_cs_precedes, but for the international format. |
int_p_sep_by_space | char | CHAR_MAX | Same as p_sep_by_space, but for the international format. |
int_n_sep_by_space | char | CHAR_MAX | Same as n_sep_by_space, but for the international format. |
int_p_sign_posn | char | CHAR_MAX | Same as p_sign_posn, but for the international format. |
int_n_sign_posn | char | CHAR_MAX | Same as n_sign_posn, but for the international format. |
""
for a member of type char*
or a value of CHAR_MAX for a member of type char
indicates that the value is not available in the locale.int_p
and int_n
(in yellow above) are defined for libraries complying with the C standard of 1999 or later (which is only required by the C++ standard since 2011: C++11).