| |||
| Home > The ARM C and C++ libraries > LC_MONETARY data block | |||
When defining a locale data block in the C library, the macros
that define an LC_MONETARY data block are as
follows:
Call LC_MONETARY_begin with
a symbol name and a locale name.
Call the LC_MONETARY data macros
as follows:
Call LC_MONETARY_fracdigits with
two arguments: frac_digits and int_frac_digits from
the lconv structure.
Call LC_MONETARY_positive with
four arguments: p_cs_precedes, p_sep_by_space, p_sign_posn and positive_sign.
Call LC_MONETARY_negative with
four arguments: n_cs_precedes, n_sep_by_space, n_sign_posn and negative_sign.
Call LC_MONETARY_currsymbol with
two arguments: currency_symbol and int_curr_symbol.
Call LC_MONETARY_point with one
argument: mon_decimal_point.
Call LC_MONETARY_thousands with
one argument: mon_thousands_sep.
Call LC_MONETARY_grouping with
one argument: mon_grouping.
Call LC_MONETARY_end, without
arguments, to finish the locale block definition.
The following example shows an LC_MONETARY data
block.
Example 6. Defining the MONETARY locale
LC_MONETARY_begin c_monetary, "C" LC_MONETARY_fracdigits 255, 255 LC_MONETARY_positive 255, 255, 255, "" LC_MONETARY_negative 255, 255, 255, "" LC_MONETARY_currsymbol "", "" LC_MONETARY_point "" LC_MONETARY_thousands "" LC_MONETARY_grouping "" LC_MONETARY_end